SQLite Forum

Internal schema cache not refreshed after DROP TABLE in different connection
OK, so it looks like you have to actually do something that needs to use
the schema before the schema is checked.  Something like this will suffice:

    SELECT 1 FROM sqlite_master LIMIT 1;

Do this inside of the transaction before preparing each CREATE or DROP statement.

I'll see what we can do about fixing this for the next release.