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

Move the sqlite3_sleep() and sqlite3_clear_bindings() interfaces into the

main library and make this official. (CVS 3316)

FossilOrigin-Name: eb3442c44ef1dbf8895195bb08fbeeea315b44c1
This commit is contained in:
drh
2006-06-27 20:06:44 +00:00
parent 0c07fb9aa1
commit f9cb7f58a7
6 changed files with 94 additions and 22 deletions

View File

@@ -14,7 +14,7 @@
** other files are for internal use by SQLite and should not be
** accessed by users of the library.
**
** $Id: main.c,v 1.349 2006/06/26 21:35:45 drh Exp $
** $Id: main.c,v 1.350 2006/06/27 20:06:45 drh Exp $
*/
#include "sqliteInt.h"
#include "os.h"
@@ -1258,3 +1258,22 @@ error_out:
return sqlite3ApiExit(db, rc);
}
#endif
/*
** Set all the parameters in the compiled SQL statement to NULL.
*/
int sqlite3_clear_bindings(sqlite3_stmt *pStmt){
int i;
int rc = SQLITE_OK;
for(i=1; rc==SQLITE_OK && i<=sqlite3_bind_parameter_count(pStmt); i++){
rc = sqlite3_bind_null(pStmt, i);
}
return rc;
}
/*
** Sleep for a little while. Return the amount of time slept.
*/
int sqlite3_sleep(int ms){
return sqlite3OsSleep(ms);
}