1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-08-08 14:02:16 +03:00

Add the experimental sqlite3_stmt_status() interface. (CVS 5781)

FossilOrigin-Name: de473efb35ffdf9a8222a70a84dfd7d3198c87c1
This commit is contained in:
drh
2008-10-07 23:46:38 +00:00
parent e82f5d04c3
commit d1d384888b
12 changed files with 225 additions and 63 deletions

View File

@@ -13,7 +13,7 @@
** This file contains code use to implement APIs that are part of the
** VDBE.
**
** $Id: vdbeapi.c,v 1.144 2008/10/07 15:25:49 drh Exp $
** $Id: vdbeapi.c,v 1.145 2008/10/07 23:46:38 drh Exp $
*/
#include "sqliteInt.h"
#include "vdbeInt.h"
@@ -1285,3 +1285,13 @@ sqlite3_stmt *sqlite3_next_stmt(sqlite3 *pDb, sqlite3_stmt *pStmt){
sqlite3_mutex_leave(pDb->mutex);
return pNext;
}
/*
** Return the value of a status counter for a prepared statement
*/
int sqlite3_stmt_status(sqlite3_stmt *pStmt, int op, int resetFlag){
Vdbe *pVdbe = (Vdbe*)pStmt;
int v = pVdbe->aCounter[op-1];
if( resetFlag ) pVdbe->aCounter[op-1] = 0;
return v;
}