Click or drag to resize
ConnectionHelper Methods

The ConnectionHelper type exposes the following members.

Methods
  NameDescription
Public methodStatic memberBuildConnectionString
Builds a connection string based on specified parameters.
Public methodStatic memberBulkInsert
Performs a bulk insert of the data into a target database table
Public methodStatic memberClear
Clears the connection helper cache
Public methodStatic memberExecuteNonQuery(String, QueryDataParameters, QueryMacros)
Executes the query and returns the number of rows affected.
Public methodStatic memberExecuteNonQuery(String, QueryDataParameters, QueryTypeEnum, Boolean)
Executes the query and returns the number of rows affected.
Public methodStatic memberExecuteNonQueryAsync(String, CancellationToken, QueryDataParameters, QueryMacros)

Executes the query asynchronously and returns the number of rows affected.

The cancellation token can be used to request that the operation be abandoned before the command timeout elapses. Exceptions will be reported via the returned Task object.

Public methodStatic memberExecuteNonQueryAsync(String, QueryDataParameters, QueryTypeEnum, CancellationToken, Boolean)

Executes the query asynchronously and returns the number of rows affected.

The cancellation token can be used to request that the operation be abandoned before the command timeout elapses. Exceptions will be reported via the returned Task object.

Public methodStatic memberExecuteQuery(QueryParameters)
Executes query and returns result as a dataset.
Public methodStatic memberExecuteQuery(String, QueryDataParameters, QueryTypeEnum, Boolean)
Runs the query.
Public methodStatic memberExecuteQuery(String, QueryDataParameters, String, String, Int32, String)
Executes query and returns result as a dataset.
Public methodStatic memberExecuteQuery(String, QueryDataParameters, String, String, Int32, String, Int32, Int32, Int32)
Executes query and returns result as a dataset.
Public methodStatic memberExecuteReader
Executes the query and returns result of the query as a DbDataReader.
Public methodStatic memberExecuteReaderAsync

Executes the query asynchronously and returns result as a DbDataReader.

The cancellation token can be used to request that the operation be abandoned before the command timeout elapses. Exceptions will be reported via the returned Task object.

Public methodStatic memberExecuteScalar(String, QueryDataParameters, QueryMacros)
Executes the query and returns the first column of the first row in the result set returned by the query. Additional columns or rows are ignored.
Public methodStatic memberExecuteScalar(String, QueryDataParameters, QueryTypeEnum, Boolean)
Executes the query and returns the first column of the first row in the result set returned by the query. Additional columns or rows are ignored.
Public methodStatic memberExecuteScalarAsync(String, CancellationToken, QueryDataParameters, QueryMacros)

Executes the query asynchronously and returns the first column of the first row in the result set returned by the query. Additional columns or rows are ignored.

The cancellation token can be used to request that the operation be abandoned before the command timeout elapses. Exceptions will be reported via the returned Task object.

Public methodStatic memberExecuteScalarAsync(String, QueryDataParameters, QueryTypeEnum, CancellationToken, Boolean)

Executes the query asynchronously and returns the first column of the first row in the result set returned by the query. Additional columns or rows are ignored.

The cancellation token can be used to request that the operation be abandoned before the command timeout elapses. Exceptions will be reported via the returned Task object.

Public methodStatic memberGetConnection
Returns the connection.
Public methodStatic memberGetConnectionByName
Returns the connection.
Public methodStatic memberGetConnectionString(String)
Gets the connection string of provided connectionStringName.
Public methodStatic memberGetConnectionString(String, Boolean)
Gets the connection string of provided connectionStringName.
Public methodStatic memberGetConnectionStringPrefix
Gets the connection string name for the given domain
Public methodStatic memberGetFirstFoundConnectionString
Gets the first found connection string by the prefix, if none found, returns null
Public methodStatic memberGetIsolationLevel
Returns the isolation level evaluated from the string representation.
Public methodStatic memberGetSqlConnectionString
Returns the connection string.
Public methodStatic memberGetSqlConnectionString(String)
Returns the connection string.
Public methodStatic memberInitRequestContext
Initializes the request context to use proper database based on current domain name
Public methodStatic memberTestConnection(String)
Tests the given connection parameters.
Public methodStatic memberTestConnection(SQLServerAuthenticationModeEnum, String, String, String, String)
Tests the given connection parameters.
Top
See Also