Skip to content

ConnectionPlus.Interface.QueryOptions

Christian d'Heureuse edited this page Oct 28, 2026 · 1 revision

tedious-plus / ConnectionPlus / QueryOptions

Interface: QueryOptions<RT>

Defined in: ConnectionPlus.ts:34

Options for ConnectionPlus.query and ConnectionPlus.queryRows.

Extends

Type Parameters

RT

RT extends RowType = RowType

Properties

paramDefArray?

paramDefArray?: SqlParamDef[];

Defined in: TediousUtils.ts:371

This variant is used to specify full parameter definitions as an array.

Example:

[
   {name: "p1", type: Tedious.TYPES.Int, value: 123},
   {name: "p2", type: Tedious.TYPES.NVarChar, value: "abc"}
]

Inherited from

CommonRequestOptions.paramDefArray


paramDefs?

paramDefs?: Record<string, SqlParamValueAndDataType>;

Defined in: TediousUtils.ts:358

This variant is used to specify full parameter definitions as an object.

Example:

{
   p1: {type: Tedious.TYPES.Int, value: 123},
   p2: {type: Tedious.TYPES.NVarChar, value: "abc"}
}

Inherited from

CommonRequestOptions.paramDefs


params?

params?: Record<string, unknown>;

Defined in: TediousUtils.ts:334

This variant is used to specify parameter names and values.

Example: {p1: 123, p2: "abc"}

The data types are derived from the values (see deriveParamDataTypeFromValue).

Inherited from

CommonRequestOptions.params


paramValues?

paramValues?: unknown[];

Defined in: TediousUtils.ts:345

This variant is used to specify only the parameter values.

Example: [123, "abc"]

The parameter names a, b, c, ... are generated (see genParamName), so the parameters are referenced as @a, @b, @c, ... in the SQL code. The data types are derived from the values (see deriveParamDataTypeFromValue).

Inherited from

CommonRequestOptions.paramValues


rowType?

rowType?: RT;

Defined in: ConnectionPlus.ts:41

The format of the returned rows.

Default Value

"ObjectRow"

timeoutMs?

timeoutMs?: number;

Defined in: ConnectionPlus.ts:24

The number of milliseconds before the request is considered failed, or 0 for no timeout. When no timeout is set, the options.requestTimeout of the Connection is used.

Inherited from

CommonRequestOptions.timeoutMs

Clone this wiki locally