I have an android list activity that is backed by a database cursor through a SimpleCursorAdapter.
i have one constraint that need to be modify the cursor data. i cannot add the constraint in query.
How should I be update cursor ?
I have an android list activity that is backed by a database cursor through a SimpleCursorAdapter.
i have one constraint that need to be modify the cursor data. i cannot add the constraint in query.
How should I be update cursor ?
You cannot manually modify the contents of a Cursor
obtained from a database query. You will need to read the data out of the Cursor
, modify it per your "constraint", and then put the results in a MatrixCursor
or an ArrayList
of model objects or something.