Lines Matching defs:db
112 static int db_table_exists(sqlite3 *db, const char *name)
116 return sqlite3_exec(db, cmd, NULL, NULL, NULL) == SQLITE_OK;
120 static int db_table_create_milenage(sqlite3 *db)
134 if (sqlite3_exec(db, sql, NULL, NULL, &err) != SQLITE_OK) {
146 sqlite3 *db;
148 if (sqlite3_open(db_file, &db)) {
150 db_file, sqlite3_errmsg(db));
151 sqlite3_close(db);
155 if (!db_table_exists(db, "milenage") &&
156 db_table_create_milenage(db) < 0) {
157 sqlite3_close(db);
161 return db;
1035 " [-D<DB file>] [-i<IND len in bits>] [command]\n"
1044 " -D<DB file> = path to SQLite database\n"