mirror of
https://github.com/sqlite/sqlite.git
synced 2025-08-08 14:02:16 +03:00
Add a new interface, sqlite3_context_db_handle(), that returns the database
connection pointer for an application-defined function. (CVS 4889) FossilOrigin-Name: 54c55cae556af5a16c0ce8be1a96d2932db80ad8
This commit is contained in:
@@ -413,6 +413,15 @@ void *sqlite3_user_data(sqlite3_context *p){
|
||||
return p->pFunc->pUserData;
|
||||
}
|
||||
|
||||
/*
|
||||
** Extract the user data from a sqlite3_context structure and return a
|
||||
** pointer to it.
|
||||
*/
|
||||
sqlite3 *sqlite3_context_db_handle(sqlite3_context *p){
|
||||
assert( p && p->pFunc );
|
||||
return p->s.db;
|
||||
}
|
||||
|
||||
/*
|
||||
** The following is the implementation of an SQL function that always
|
||||
** fails with an error message stating that the function is used in the
|
||||
|
Reference in New Issue
Block a user