QueryResult
The object resolved by SqbClient.execute() and
SqbConnection.execute(). See
Executing Queries for the full
usage guide.
interface QueryResult {
executeTime: number;
fields?: FieldInfoMap;
rows?: any;
rowType?: 'array' | 'object';
query?: QueryRequest;
returns?: any;
rowsAffected?: number;
cursor?: Cursor;
}
| Field | Type | Description |
|---|---|---|
executeTime | number | Milliseconds the query took, measured around the adapter call. |
fields | FieldInfoMap | Column metadata, populated for statements that return rows. Look up a field by name with result.fields.get('columnName'). |
rows | any | The fetched rows (object or array rows, per rowType/objectRows) — absent when cursor: true was requested. |
rowType | 'array' | 'object' | The row shape reported by the adapter before naming/object normalization. |
query | QueryRequest | The executed request (SQL, params, effective options) — only populated when showSql: true. |
returns | any | Adapter-specific return value passthrough. |
rowsAffected | number | Affected-row count, populated for statements like UPDATE/DELETE. |
cursor | Cursor | Populated instead of rows when cursor: true was requested — see Cursors & Streaming. |