mardi 31 mars 2015

Filter and display SQLite data by date in listview

I have a SQLite table with date (format: %Y-%m-%d) in one column. Currently the listview is populated with data belonging to all dates. However, I want to populate the listview for a specific date. The specific date need to be provided by the user.


What I did was to get date, month, year in 3 separate editText from the user, add/append the strings. The appended value is then used as a Selection parameter in cursor query. However, on execution I am getting illegalargumentexception. I know that the procedure I followed is probably incorrect. Can someone describe me the right way to populate the listview data by date?


Aucun commentaire:

Enregistrer un commentaire