Note that there are some explanatory texts on larger screens.

plurals
  1. POMalformed SQLite Database Without Exception Being Thrown
    primarykey
    data
    text
    <p>I have an SQLite database with records being inserted into it for my Android app.</p> <p>I am inserting the answers to on screen surveys, with one answer saved per row in my table.</p> <p>My surveys have 20 questions, and it inserts the answers correctly to the database for the first survey, but then when I insert the answers for the second survey (programatically the same questions, just done again) it malforms the database, but never throws an exception or anything. I run an integrity check before and after and it always returns true.</p> <p>The unusual thing is that it is only malformed when I try to look at the table on my computer. I tried using the SQLite Database Browser tool, TKSQLite tool, and then opening the DB from the supplied sqlite3.exe, and they all seem to show the DB as malformed. Although the TKSQLite tool notifies me that the table is malformed, I can get the data in other tables. The SQLite Database Browser just shows no data in the table, and sqlite3.exe won't open any tables.</p> <p>The very unusual thing is if I query the table in the app and print the cursor rows out to log cat, or use the data within the app, all the data is there.</p> <p>Has anyone seen only partial malformation without an exception being thrown? I would like my database to be pristine...but if my data is there can I hope that it won't get any more malformed?</p> <p>I worked with SQLite databases for a few projects now doing similar things, and this is the first time I am seeing only partial malformation.</p> <p>If it will help I am using the Acer a501 tablet programming on Honeycomb 3.2</p> <p>Additionally, I am accessing the database using a static singleton, to avoid opening and closing the database too often for each insert, and originally inserted via SQL commands using <code>execSQL()</code>, but have also tried using the SQLiteDatabase method <code>insert()</code> to no avail.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload