android ListView subitem database

I’m making an application with a database of courses (of school) that the user is participating in. I want to display those courses in a list (im using listview) and use also the subitem (extra information of that course) of the listitems. I found a tutorial ( that displays a list like I want but it uses a class to store the data in instead of a database. So the tutorial uses an arraylist of objects of that class. It would be a detour though if i had to put my information from my database into a class to put it in the list.

Does anyone have a clue how to solve this?



I found a beter way. By using a simple adapter and putting the values of the cursor in a hashmap in a arraylist. Found the idea from this site: