Skip to main content

sqlite3_exec

Function sqlite3_exec 

Source
#[unsafe(no_mangle)]
pub unsafe extern "C" fn sqlite3_exec( db: *mut Sqlite3, sql: *const c_char, callback: Option<unsafe extern "C" fn(parg: *mut c_void, ncols: c_int, values: *mut *mut c_char, names: *mut *mut c_char) -> c_int>, parg: *mut c_void, errmsg: *mut *mut c_char, ) -> c_int
Expand description

Execute one or more SQL statements.

§Safety

  • db must be a valid handle from sqlite3_open.
  • sql must be a valid null-terminated C string.
  • callback may be null. If non-null, it is invoked for each result row.
  • errmsg may be null. If non-null and an error occurs, it is set to a malloc’d string that the caller must free with sqlite3_free.