Skip to main content

ScriptExecuteOptions

Extends DataMappingOptions

KeyTypeDefaultDescription
autoCommitbooleantrueSpecifies whether to execute the script in auto-commit mode
objectRowsbooleanfalseSpecifies whether rows are fetched as <FieldName, Value> pair objects or as arrays of values
typeMapDataTypeMapGlobalTypeMapData type map instance
rollbackOnErrorbooleantrueWhen off, if a statement in a transaction block generates an error, the error is ignored and the transaction continues. When on (the default), a statement in a transaction block that generates an error aborts the entire transaction
signalAbortSignalAborts the call when the signal fires: the running script is cancelled on the server and the promise rejects with the signal's own reason, with the database error attached as cause. Cancelling is a request rather than a guarantee — the call settles when the server has actually finished, not the moment abort() is called. AbortSignal.timeout(ms) gives a per-call timeout
asyncErrorHandlingbooleanthe connection's own settingOverrides the connection's own asyncErrorHandling for this call only — see DatabaseConnectionParams.asyncErrorHandling

ScriptExecuteOptions has no cursor, params, columnFormat or fetchCount fields — those are specific to QueryOptions; a script is a batch of Simple Query statements with no bind parameters and no cursor support.