I am writing an application for Android version 3.2, then the ASUS Eee Pad TF01 which requested an upgrade, this changed the version of Android to 4.0.3.
Since then I have issues with the app, I tracked this down to the SQLite DB it stops with an error on a table not existing.
I have then comparing to the NOTEPAD example app, which worked. In my App to create the DB I read a creation script from a file into a String then use execSQL, this worked fine before, but for this is not working now. I checked some other things
- The file is still being read ok,
- After reducing the contents of the file to two tables, still doesn’t work
- Checked the file on SQLite databse browser (2.0b1) tools under Windows, no problem
I think it may be the characters (Collation type) or maybe the character coding in the SQL file, or invalid characters.
Any idea how I can solve this issue ?
This was caused by execsql not processing multiple SQL commands,
see – Executing multiple statements with SQLiteDatabase.execSQL for a full explanation.
How this worked before, it is a mystery …