I am working on a project that has to enter about 80,000 row entries into a database per run. I’ve been able to speed it up a lot thanks to prepared statements. However, I am running into a problem where one last area where I need to make a lot of row entries relies on data from SELECT calls made between INSERT statements due to the involvement of foreign keys. In all of the examples I have seen of prepared statements, it was all for ExecuteNonQuery() command calls.
Am I allowed to use prepared statements with a SELECT query call in the same transaction as INSERT calls as long as nothing besides the values are changed in the SQLiteCommand.CommandText values or is there a different way I need to approach this?
You can execute a
SELECTcommand using prepared statements, but you’ll have to create one moreSQLiteCommandobject.