I get such stack trace:
android.database.sqlite.SQLiteException: no such table: someTa???: , while compiling: SELECT COUNT(*) FROM someTa??? WHERE a = ? AND b = ?
at android.database.sqlite.SQLiteCompiledSql.native_compile(Native Method)
at android.database.sqlite.SQLiteCompiledSql.compile(SQLiteCompiledSql.java:91)
at android.database.sqlite.SQLiteCompiledSql.<init>(SQLiteCompiledSql.java:64)
at android.database.sqlite.SQLiteProgram.<init>(SQLiteProgram.java:80)
at android.database.sqlite.SQLiteQuery.<init>(SQLiteQuery.java:46)
at android.database.sqlite.SQLiteDirectCursorDriver.query(SQLiteDirectCursorDriver.java:42)
at android.database.sqlite.SQLiteDatabase.rawQueryWithFactory(SQLiteDatabase.java:1345)
at android.database.sqlite.SQLiteDatabase.rawQuery(SQLiteDatabase.java:1315)
Notice that the SQL is corruped, instead of someTable I see someTa???, where ? stands for char 0x1A. This happens only sometimes (very rare).
I create SQL query string using StringBuilder and String.format.
The question is who is corrupting memory? Is this Android runtime, or SQLite? May be this is a known bug?