MCPcopy Create free account
hub / github.com/bloomberg/comdb2 / new_dbstmt

Function new_dbstmt

lua/sp.c:2610–2621  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2608}
2609
2610dbstmt_t *new_dbstmt(Lua lua, SP sp, sqlite3_stmt *stmt)
2611{
2612 dbstmt_t *dbstmt;
2613 new_lua_t(dbstmt, dbstmt_t, DBTYPES_DBSTMT);
2614 dbstmt->stmt = stmt;
2615 dbstmt->num_tbls = stmt_num_tbls(stmt);
2616 if (dbstmt->num_tbls) {
2617 LIST_INSERT_HEAD(&sp->dbstmts, dbstmt, entries);
2618 }
2619 dbstmt->readonly = sqlite3_stmt_readonly(stmt);
2620 return dbstmt;
2621}
2622static int dbtable_where(lua_State *lua)
2623{
2624 SP sp = getsp(lua);

Callers 3

dbtable_whereFunction · 0.85
db_execFunction · 0.85
db_prepareFunction · 0.85

Calls 2

stmt_num_tblsFunction · 0.85
sqlite3_stmt_readonlyFunction · 0.85

Tested by

no test coverage detected