dotConnect for DB2 Documentation
Devart.Data.DB2 Namespace / DB2Connection Class
Properties Methods Events

In This Topic
    DB2Connection Class Members
    In This Topic

    The following tables list the members exposed by DB2Connection.

    Public Constructors
     NameDescription
    Public ConstructorOverloaded. Initializes a new instance of the DB2Connection class.  
    Top
    Public Properties
     NameDescription
    Public PropertyOverridden. Gets or sets the string used to open a DB2 connection.  
    Public PropertyOverridden. Gets the time to wait while trying to establish a connection before terminating the attempt and generating an error.  
    Public PropertyGets the System.ComponentModel.IContainer that contains the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
    Public PropertyGets or sets the name of the current database or the database to be used once a connection is open.  
    Public PropertyOverridden. Gets or sets the name or network address of the DB2 server instance to which to connect.  
    Public PropertyIndicates whether the connection is enlisted in a distributed transaction. (Inherited from Devart.Common.DbConnectionBase)
    Public PropertyDetermines whether a failover operation can be performed after connection breaks.  
    Public PropertyGets or sets the name of the component.  
    Public PropertyGets or sets a form or other container that the DB2Connection instance belongs to.  
    Public PropertyGets or sets the user's password to connect.  
    Public PropertyGets or sets the host and port to connect to. For example, "db2server:5000". Port may be omitted.  
    Public PropertyThis property applies to UniData® and UniVerse data servers only. Indicates whether the connection is to be made to UniData or UniVerse.  
    Public PropertyOverridden. Gets a string containing the version of the instance of DB2 to which the client is connected.  
    Public PropertyGets or sets the System.ComponentModel.ISite of the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
    Public PropertyGets the current state of the connection.  
    Public PropertyGets or sets the name of the user to connect.  
    Top
    Public Methods
     NameDescription
    Public MethodStarts an asynchronous invocation of an Open method. (Inherited from Devart.Common.DbConnectionBase)
    Public MethodOverloaded. Begins a transaction at the database.  
    Public MethodOverridden. Changes the current database associated with an open connection.  
    Public Methodstatic (Shared in Visual Basic)Clears all pools associated with the connection.  
    Public Methodstatic (Shared in Visual Basic)Clears the pool matching ConnectionString of provided DB2Connection object.  
    Public MethodCreates a new object that is a copy of the current instance.  
    Public MethodCloses the connection to the database. This is the preferred method of closing any open connection. (Inherited from Devart.Common.DbConnectionBase)
    Public MethodCreates and returns a DB2Command object associated with the DB2Connection.  
    Public MethodCreates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (Inherited from System.MarshalByRefObject)
    Public MethodReleases all resources used by the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
    Public MethodEnds an asynchronous invocation of the Open method. (Inherited from Devart.Common.DbConnectionBase)
    Public MethodEnlists in the specified transaction as a distributed transaction.  
    Public MethodOverridden. Enlists in the specified transaction.  
    Public MethodRetrieves the current lifetime service object that controls the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
    Public MethodOverloaded. Returns list of metadata collections and number of restrictions for a collection. (Inherited from Devart.Common.DbConnectionBase)
    Public MethodObtains a lifetime service object to control the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
    Public MethodOverridden. Opens a DB2 connection with the property settings specified by the ConnectionString.  
    Public MethodReturns a System.String containing the name of the System.ComponentModel.Component, if any. This method should not be overridden. (Inherited from System.ComponentModel.Component)
    Top
    Public Events
     NameDescription
    Public EventOccurs when connection to the data source is lost in case LocalFailover is set to true. You may use this event to implicitly reconnect and reexecute the current operation.  
    Public EventOccurs when the component is disposed by a call to the System.ComponentModel.Component.Dispose method. (Inherited from System.ComponentModel.Component)
    Public EventOccurs when DB2 returns an error.  
    Public EventOccurs when DB2 returns a warning or informational message.  
    Public EventOccurs when the state of the connection changes. (Inherited from Devart.Common.DbConnectionBase)
    Public EventOccurs when the state of the transaction is changed. (Inherited from Devart.Common.DbConnectionBase)
    Public EventOccurs when the state of the transaction is changing. (Inherited from Devart.Common.DbConnectionBase)
    Top
    See Also