I am writing a C program and running some queries using sqlite. I do not use sqlite3_exec() , since you cannot get results without writing a callback function for it.
So, I have a source that looks something like this:
char * query = "CREATE TABLE 'items' (id int, icon int, name text); CREATE TABLE 'icons' (id int, image blob); CREATE TABLE 'playfields' (id int, name text);"; sqlite3_prepare_v2(dump_db_into,query,-1,&sqlstmt,0); sqlite3_step(sqlstmt);
And, of course, only the first request is executed. Do I need to run sqlite3_step() several times?
I would prefer not to run these commands again and again if I have a large number of requests
source share