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

Function dont_cache_this_sql

db/sql_stmt_cache.c:506–509  ·  view source on GitHub ↗

This is called at the time of put_prepared_stmt_int() * to determine whether the given sql should be cached. * We should not cache ddl stmts, analyze commands, * rebuild commands, truncate commands, explain commands. * Ddl stmts and explain commands should not get to * put_prepared_stmt_int() so are not handled in this function. * However, most of these cases are now handled via the custom

Source from the content-addressed store, hash-verified

504 * EXPLAIN case.
505 */
506static inline int dont_cache_this_sql(struct sql_state *rec)
507{
508 return sqlite3_stmt_isexplain(rec->stmt);
509}
510
511/* return code of 1 means we encountered an error and the caller
512 * needs to cleanup this rec->stmt */

Callers 1

stmt_cache_put_intFunction · 0.85

Calls 1

sqlite3_stmt_isexplainFunction · 0.85

Tested by

no test coverage detected