API reference › @evolu/sqlite-wasm › c-api › sqlite3_deserialize
function sqlite3_deserialize(
deps: SqliteWasmDep,
): (
db: SqliteDbPtr,
zSchema: 0 | CStringPtr,
pData: WasmPtr,
szDb: bigint,
szBuf: bigint,
mFlags: number,
) => SqliteResultCode;
Defined in: packages/sqlite-wasm/src/CApi.ts:1549
Reopens a schema, main for NULL, as an in-memory database over the first szDb bytes of a szBuf-byte buffer, which must stay valid and unmodified until the connection closes. szBuf must be at least szDb, and about 20 bytes more for content that may be malformed, which SQLite may read a few bytes past. With SQLITE_DESERIALIZE_FREEONCLOSE, SQLite takes ownership of the sqlite3_malloc'd buffer and frees it, even when deserializing fails.
Wasm type i(iiijji). Signature ["sqlite3_deserialize", "int", "sqlite3*", "string", "*", "i64", "i64", "int"] from SQLite's table.