MCPcopy Create free account
hub / github.com/davidgiven/fluxengine / hasProperties

Function hasProperties

tools/upgrade-flux-file.cc:57–75  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

55}
56
57bool hasProperties(sqlite3* db)
58{
59 sqlite3_stmt* stmt;
60 sqlCheck(db,
61 sqlite3_prepare_v2(db,
62 "SELECT COUNT(*) FROM sqlite_master WHERE type='table' AND "
63 "name='properties'",
64 -1,
65 &stmt,
66 NULL));
67
68 int i = sqlite3_step(stmt);
69 if (i != SQLITE_ROW)
70 error("Error accessing sqlite metadata");
71 bool has_properties = sqlite3_column_int(stmt, 0) != 0;
72 sqlCheck(db, sqlite3_finalize(stmt));
73
74 return has_properties;
75}
76
77void sql_bind_blob(sqlite3* db,
78 sqlite3_stmt* stmt,

Callers 1

sqlReadIntPropertyFunction · 0.85

Calls 2

sqlCheckFunction · 0.85
errorFunction · 0.85

Tested by

no test coverage detected