Global

Type Definitions

MSConnectionOptions

MSSQL specific extension of the SQLERConnectionOptions from the sqler module.

Properties:
Properties
Name Type Description
driverOptions Object

The mssql module specific options. Both client and pool will be merged when generating the connection pool.

Name Type Attributes Description
connection Object <optional>

An object that will contain properties/values that will be used to construct the MSSQL connections (e.g. { database: 'mydb', requestTimeout: 10000 }). See the mssql module documentation for a full listing of available connection options. When a property value is a string surrounded by ${}, it will be assumed to be a property that resides on either the SQLERPrivateOptions passed into the Manager constructor or a property on the MSConnectionOptions itself (in that order of precedence). For example, connOpts.host = '127.0.0.1' and driverOptions.connection.host = '${host}' would be interpolated into driverOptions.connection.host = '127.0.0.1'. In contrast to privOpts.username = 'someUsername' and driverOptions.connection.user = '${username}'would be interpolated intodriverOptions.connection.user = 'someUsername'. Also, any other interpolated values will be assumed to be a _constant_ property that resides on the mssqlmodule and will be interpolated accordingly. For exampledriverOptions.connection.pool.someProp = '${SOME_MSSQL_CONSTANT}'will be interpolated aspool.someProp = mssql.SOME_MSSQL_CONSTANT. __Using any of the generic pool.someOptionwill override theconfoptions set ondriverOptions.connection.pool__ (e.g. pool.max = 10would override driverOptions.connection.pool.max = 20`).

Source:
Type:
  • SQLERConnectionOptions

MSExecOptions

MSSQL specific extension of the SQLERExecOptions from the sqler module. When a property of binds contains an object it will be interpolated for property values on the mssql module. For example, binds.name = '${SOME_MSSQL_CONSTANT}' will be interpolated as binds.name = mssql.SOME_MSSQL_CONSTANT.

Properties:
Properties
Name Type Attributes Description
driverOptions Object <optional>

The mssql module specific options pertaining executions

Name Type Attributes Description
inputBindTypes Object <optional>

An object that contains properties that match the bind parameter names. Each property should contain a value that corresponds to a mssql module specific bind type. Each bind type will result in a call to either mssql.Request.input, mssql.PreparedStatement.input. When using preparedStatement = true, input bind types are required. When a property value is a string surrounded by ${}, it will be assumed to be a property that resides on the mssql module itself. For example, driverOptions.inputBindTypes.name = '${VarChar}' would be interpolated into driverOptions.inputBindTypes.name = mssql.VarChar.

outputBindTypes Object <optional>

An object that contains properties that match the bind parameter names. Each property should contain a value that corresponds to a mssql module specific bind type. Each bind type will result in a call to either mssql.Request.output, mssql.PreparedStatement.output. When a property value is a string surrounded by ${}, it will be assumed to be a property that resides on the mssql module itself. For example, driverOptions.outputBindTypes.name = '${VarChar}' would be interpolated into driverOptions.outputBindTypes.name = mssql.VarChar.

Source:
Type:
  • SQLERExecOptions

MSPlan

Transactions are wrapped in a parent transaction object so private properties can be added

Properties:
Name Type Attributes Description
txo MSTransactionObject <optional>

The transaction object

stmt MSPreparedStatement <optional>

The prepared statement object (undefined when none)

req Object <optional>

The MSSQL request (undefined when using only prepared statement(s))

run MSPlanRunner <optional>

The SQL executor for the plan

Source:
Type:
  • Object

(async) MSPlanRunner(sql)

Will either prepare/execute the passed SQL or query the passed SQL

Source:
Parameters:
Name Type Description
sql String

The SQL statement that contains the bind parameters

MSPreparedStatement

Prepared statements are wrapped in a parent prepared statement object so private properties can be added

Properties:
Name Type Attributes Description
ps Object

The MSSQL prepared statement

txId String <optional>

The transaction that the prepared statement is participating in (if any)

Source:
Type:
  • Object

MSTransactionObject

Transactions are wrapped in a parent transaction object so private properties can be added

Properties:
Name Type Description
tx SQLERTransaction

The transaction

msTx Obejct

The MSSQL transaction

Source:
Type:
  • Object

MSTransactionOptions

Properties:
Properties
Name Type Attributes Description
driverOptions Object <optional>

The mssql module specific options pertaining to transations

Name Type Attributes Description
isolationLevel String <optional>

Controls the locking and row versioning behavior of MSSQL statements issued by a connection. When a property value is a string surrounded by ${}, it will be assumed to be a constant property that resides on the mssql module within mssql.ISOLATION_LEVEL and will be interpolated accordingly. For example driverOptions.isolationLevel = ${SERIALIZABLE} will be interpolated to driverOptions.isolationLevel = mssql.ISOLATION_LEVEL.SERIALIZABLE.

Source:
Type:
  • SQLERTransactionOptions

3.0.0 (2021-05-07)

Full Changelog

Breaking Changes: