Up |
_sqliteCallbackExec
Reflex called to each request done by _sqliteExec and which return a value (such as 'SELECT ...').
Prototype :
fun [ObjSqlite fun [ObjSqlite u0 S S] u1 u0] ObjSqlite
- ObjSqlite : a sqlite3 object.
- fun [ObjSqlite u0 S S] u1 : the callback. Supplemental arguments are the column and the value
- u0 : an user parameter at your convenience, given to the callback.
Return : ObjSqlite the same object or nil if an error occurs.
See also :
Example :
fun mycallback (db, uparam, column, value)=
_fooS strcat "user parameter : " uparam;
_fooS strcat "column : " column;
_fooS strcat "value : " value;
0;;
fun main ()=
_showconsole;
let _sqliteOpenFile _channel _checkpack "tests/db/sqlite3/test_1.sqlite3" -> mydb in
if mydb == nil then
// do something
else
(
...
_sqliteCallbackExec mydb @mycallback "this is my callback";
...
);
0;;