When I write a ContentProvider that querying the Sqlite. I using the simple code as bellow. I get this weird the column doesn't not exist error. what make me confusing that the DBHelper has been worked well for a time.
Also I defined the _ID column.
|Code Of DBHelper|
How to fix it?
1. Make sure the you have a Column of _id, the column name here is case sensitive. the internal logic use “_id” as a key query to the dictionary.
2. Since the DBCreation Logic once be invoked Once. So either Remove the DB file manually which is located in /data/data/yourappnamespace/databases
or just rename the table name in your sql to reflect the changes. otherwise, you keep polling the Prevous defined DB even you changed your code.