TableRunner.insert() method
Home > @direct-sqlite/core > TableRunner > insert
TableRunner.insert() method
Section titled “TableRunner.insert() method”Runs an atomic single-record write payload tracking metadata state alterations.
Signature:
insert(data: Partial<TRow>): { changes: any; lastInsertRowId: number; };Parameters
Section titled “Parameters”|
Parameter |
Type |
Description |
|---|---|---|
|
data |
Partial<TRow> |
An object containing the columns and their values to be inserted. |
Returns:
{ changes: any; lastInsertRowId: number; }
The result of the insert operation, which typically includes the number of changes made and the last inserted row ID. The exact structure of the result may depend on the underlying SQLite client being used.