DB2 10.5 for Linux, UNIX, and Windows

DB2ConnectionStringBuilder members

Represents a set of methods and properties that provide generic and IBM® Data Server Provider for .NET-specific approaches to generating valid connection strings. The following tables list the members exposed by the DB2ConnectionStringBuilder class.

Public Constructors

Constructor Description
public method DB2®ConnectionStringBuilder() Initializes a new instance of the DB2ConnectionStringBuilder class.
public method DB2ConnectionStringBuilder(string) Initializes a new instance of the DB2ConnectionStringBuilder class, using an existing ConnectionString.

Public Properties

Property Description
public property allowDynamicSQL Specifies whether to allow an application to run dynamically any SQL statements that are not captured in a pureQueryXML file or that are captured but not bound.
public property Authentication Gets or sets the value of the authentication keyword.
public property capturedOnly Specifies whether to run only the SQL statements that are in the pureQueryXML file.
public property captureMode Gets or sets the value that determines if dynamically executed statements are captured for client optimization using pureQuery. An error is thrown if captureMode=on while executionMode=STATIC.
Data server restrictions:

This property applies only to DB2 data servers.

public property ClientAccountingString Gets or sets a client accounting string that is sent to a database.
public property ClientApplicationName Gets or sets a client application name that is sent to a database.
public property ClientCorrelationToken Gets or sets the client correlation token name on DB2 for z/OS Version 11 server with new function mode (NFM).
public property ClientEncAlg Gets or sets a value that determines whether AES encryption is being used.
public property CLISchema Gets or sets a value that indicates the schema to be used. If you set this property, the system catalog tables are not queried to generate the result sets. The static tables that you create by using the db2ocat tool are queried instead.
public property ClientUserID Gets or sets a client user ID that is sent to a database.
public property ClientWorkstationName Gets or sets a client workstation name that is sent to a database.
public property CodePage The CodePage property gets or sets the current Encoding's code page identifier. It is a read/write property that allows users to specify how strings are encoded in their applications.
public property ConcurrentAccessResolution Specifies the Concurrent Access Resolution to be used.
public property Connect_Timeout Gets or sets the number of seconds to wait before a connection attempt times out.
public property ConnectNodeNumber Specifies the database partition server to which a connection is to be made.
public property ConnectionLifeTime Gets or sets the number of seconds that a connection can remain idle in the connection pool.
public property ConnectionReset Gets or sets a value that determines whether a connection is placed in the connection pool when the connection is closed.
public property ConnectionString (inherited from DbConnectionStringBuilder) Gets or sets the connection string that is associated with the DbConnectionStringBuilder.
public property Count (inherited from DbConnectionStringBuilder) Gets the current number of keys that are in the ConnectionString property.
public property CurrentFunctionPath Gets or sets the list of schema name that can be used to resolve function references and data type references in dynamic SQL statements.
public property CurrentPackageSet Issues the SET CURRENT PACKAGESET statement after every connection.
public property CurrentSchema Gets or sets the value of the schema name that is used for all unqualified SQL objects that are used in the connection.
public property CurrentSQLID Gets or sets the value of the SQLID that is used for all unqualified SQL objects that are used in the connection to DB2 for z/OS.
public property Database Gets or sets the value of the database to connect to.
public property DBName Gets or sets the value of the DBName keyword.
public property Delimident Gets or sets a value that indicates whether any string within double quotation marks (") is treated as an identifier and any string within single quotation marks (') is treated as a string literal.
Data server restrictions:

This property applies only to Informix®.

public property enableDynamicSQLReplacement Specifies whether to run alternative SQL statements that were added to a pureQueryXML file and both the original statements and the alternative statements were not bound.
public property Enlist Gets or sets the value that indicates whether automatic enlistment in the Distributed Transaction Coordinator (DTC) is enabled.
public property EnsureDefaultDFRM Gets or sets a value that indicates whether the DB2Connection.Open() method attempts to explicitly set the rounding mode to ROUND_HALF_EVEN.
Data server restrictions:

This property applies only to DB2 Database for Linux, UNIX and Windows data servers.

public property executionMode Gets or sets whether previously captured statements should be executed statically for client optimization using pureQuery. An error is thrown if captureMode=on while executionMode=STATIC.
Data server restrictions:

This property applies only to DB2 data servers.

public property FitHighPrecisionType Gets or sets a value that indicates how the provider should convert high precision data so the high precision data types can be retired as .NET system types.
public property HostVarParameters Gets or sets the value indicating whether host variable support are enabled. Host variables are parameters prefixed with a colon (:).
public property Interrupt Gets or sets the interrupt processing mode.
public property IsFixedSize Gets a value that indicates whether the DB2ConnectionStringBuilder has a fixed size.
public property IsolationLevel Gets or sets a value of the isolation level for the connection.
public property IsReadOnly (inherited from DbConnectionStringBuilder) Gets a value that indicates whether the DbConnectionStringBuilder is read only.
public property Keys Gets an ICollection that contains the keys in the DB2ConnectionStringBuilder.
public property MapDate Gets or sets a value that indicates whether DATE types are reported as a different data type.
public property MapTime Gets or sets a value that indicates whether TIME types are reported as a different data type.
public property MapTimestamp Gets or sets a value that indicates whether TIMESTAMP types are reported as a different data type.
public property maxNonParmSQL Specifies the maximum number of non-parameterized SQL statements to capture. This option applies only when the value of captureMode is ON. When captureMode is OFF, pureQuery ignores this parameter.
public property MaxPoolSize Gets or sets a value that represents the maximum connection pool size.
public property MinPoolSize Gets or sets a value that represents the minimum connection pool size.
public property NewPWD Gets or sets a value that represents the new password for the user.
public property Password Gets or sets a value that represents the user password.
public property PersistSecurityInfo Gets or sets a value that indicates whether security-sensitive information, such as a password, can be returned as part of a connection string after the connection is opened or if the connection was ever open.
public property Pooling Gets or sets a value that indicates whether connection pooling is turned on.
public property ProgramId Gets or sets the client program ID to a user-defined Id that associates a connection to a database.
public property ProgramName Gets or sets the client program name to a user-defined name at the server during program monitoring.
public property propertiesGroupId Specifies a runtime group ID in a repository that is created in a database.
public property pureQueryXML Gets or sets the file name and path of the capture file.
Data server restrictions:

This property applies only to DB2 data servers.

public property pureQueryXmlRepository Specifies the repository that contains the pureQueryXML file data that is used with a .NET application enabled with pureQuery client optimization.
public property QueryTimeout Gets or sets a value of the QueryTimeout keyword.
public property repositoryRequired Specifies the pureQuery client optimization behavior if errors occur during retrieving or writing pureQuery data.
public property SchemaList Gets or sets a value of the SchemaList keyword.
public property Security

If set to SSL, specifies that SSL is to be used as a secure transport.

public property Server Gets or sets a value that specifies the host and port number to connect to.
public property SkipSynonymProcessing Specifies whether IBM Data Server Provider for .NET sends a connection string to the DbPermission.Add method, without passing through the DB2ConnectionStringBuilder class.
public property sqlLiteralSubstitution Specifies whether to capture and consolidate SQL statements that share syntax but differ only in the literal values by having pureQuery substitute parameter markers for the literal values.
public property SSLClientKeystash Specifies the SSL stash file used for an SSL connection.
public property SSLClientKeystoredb Specifies the SSL key database file that is used for an SSL connection.
public property SSLClientKeystoreDBPassword Specifies the SSL key database file that is used for an SSL connection.
public property SSLClientLabel Specifies the SSL key database file that is used for an SSL connection.
public property StatementConcentrator Gets or sets the value determining whether or not to override server configurations for statement concentrator literals.
public property SysSchema Gets or sets a value of the SysSchema keyword.
public property TableType Gets or sets a value of the TableType keyword.
public property TargetPrincipal

Fully qualified Kerberos principal name for the target server; that is, the fully qualified Kerberos principal of the DB2 instance owner in the form of name/instance@REALM. For Windows operating systems, the fully qualified Kerberos principal name is the logon account of the DB2 server service in the form of userid@DOMAIN, userid@xxx.xxx.xxx.com, or domain\userid.

public property traceFile Gets or sets the pureQuery log file used for client optimization.
Data server restrictions:

This property applies only to DB2 data servers.

public property traceLevel Specifies the level of detail to write to the log file.
public property TrustedContextSystemUserID Specifies the trusted context SYSTEM AUTHID that is used with the connection.
public property TrustedContextSystemPassword Specifies the password corresponding to the trusted context SYSYTEM AUTHID that is used with the connection.
public property UserID Gets or sets a value that represents the user name.
public property Values Gets an ICollection that contains the values in the DB2ConnectionStringBuilder.

Public Methods

Method Description
public method Add (inherited from DbConnectionStringBuilder) Adds an entry with the specified key and value into the DbConnectionStringBuilder.
public method Clear Clears the contents of the DB2ConnectionStringBuilder instance.
public method ContainsKey Determines whether the DB2ConnectionStringBuilder contains the specified key.
public method Equals (inherited from Object) Determines whether two Object instances are equal.
public method EquivalentTo (inherited from DbConnectionStringBuilder) Compares the connection information in this DbConnectionStringBuilder object with the connection information in the supplied object.
public method GetHashCode (inherited from Object) Serves as a hash function for a particular type. GetHashCode is suitable for use in hashing algorithms and data structures like a hash table.
public method GetType (inherited from Object) Gets the Type of the current instance.
public method Remove Removes the entry with the specified key from the DB2ConnectionStringBuilder.
public method ShouldSerialize Indicates whether the specified key exists in this DB2ConnectionStringBuilder instance.
public method ToString (inherited from DbConnectionStringBuilder) Returns the connection string associated with this DbConnectionStringBuilder.
public method TryGetValue Retrieves a value from the DB2ConnectionStringBuilder corresponding to the specified key.