Click or drag to resize
GeneralConnection Class
Represents a general database connection.
Inheritance Hierarchy
SystemObject
  CMS.DataEngineGeneralConnection

Namespace: CMS.DataEngine
Assembly: CMS.DataEngine (in CMS.DataEngine.dll) Version: 9.0.0
Syntax
C#
[SerializableAttribute]
public class GeneralConnection : ISerializable, 
	IDataConnection, IDisposable

The GeneralConnection type exposes the following members.

Constructors
  NameDescription
Protected methodGeneralConnection(String)
Constructor.
Public methodGeneralConnection(SerializationInfo, StreamingContext)
Constructor for deserialization.
Top
Fields
  NameDescription
Protected fieldmConnectionGuid
Connection GUID to identify the connection.
Protected fieldmDataConnection
Data connection for specific provider.
Top
Properties
  NameDescription
Public propertyAdvancedSettings
Advanced settings.
Public propertyCacheDependency
Cache dependency for the cached items.
Public propertyCacheMinutes
Cache minutes for which the selected data should be cached (only for SELECT queries).
Public propertyCommandTimeout
Command timeout.
Public propertyConnectionGuid
Connection GUID to identify the connection.
Public propertyConnectionString
Connection string for specific provider.
Public propertyDataConnection
Data connection for specific provider.
Public propertyDisableConnectionDebug
If true, the debug is disabled on this connection
Public propertyDisableQueryDebug
If true, the debug of the executed queries is disabled on this connection
Public propertyFireErrorOnExecute
If true, an error if fired on execution (for debug purposes).
Public propertyKeepOpen
If true, the connection stays open even if close is requested.
Public propertyUserID
ID of the current user.
Public propertyUseScopeConnection
If true, the connection uses the scope connection
Top
Methods
  NameDescription
Public methodBulkInsert
Performs a bulk insert of the data into a target database table
Public methodClose
Closes the connection.
Public methodDispose
Disposes the connection
Public methodExecuteNonQuery
Runs the query.
Public methodExecuteQuery(QueryParameters)
Executes query and returns result as a dataset.
Public methodExecuteQuery(QueryParameters, Int32)
Executes query and returns result as a DataSet. Returns the total number of result items.
Public methodExecuteReader
Runs the query and returns result as Data reader. Keeps the connection open.
Public methodExecuteScalar
Runs the query and returns result as a single value.
Public methodGetExecutingConnection
Gets the connection that executes the given query
Public methodGetObjectData
Gets object data.
Public methodIsOpen
Returns true if the connection is open.
Public methodLogQueryEnd
Logs the end of the query processing.
Public methodLogQueryStart
Logs query start. Logs the query to the file and to current request log for debugging.
Public methodOpen
Opens the connection.
Protected methodRunQuery
Runs the query against SQL DB.
Top
See Also