ClientApplicationName IBM data server driver configuration keyword

The ClientApplicationName keyword is used to set the client application name that is sent to a database. Applications that do not specify the application name by default can use the ClientApplicationName keyword to provide the application name.

Equivalent CLI keyword
ClientApplName
Equivalent IBM® data server provider for .NET connection string keyword
ClientApplicationName
IBM data server driver configuration file (db2dsdriver.cfg) syntax
<parameter name="ClientApplicationName" value="application name"/>
Default setting:
None
Equivalent environment or connection attribute:
SQL_ATTR_INFO_APPLNAME
Usage notes:
 The CLI driver and .NET provider has a limit of 255 characters for the ClientApplicationName keyword.
Database servers enforce different limitation in the length of the value and can truncate it. Note the following conditions:
  • Db2® for z/OS® Version 11 servers in new function mode (NFM) support a length of up to 255 characters for the CURRENT CLIENT_APPLNAME special register.
  • Db2 for z/OS Version 10 and earlier servers support a length of up to 32 characters.
  • Db2 for IBM i V6R1 and later servers support a length of up to 255 characters.
To ensure that the data is converted correctly when transmitted to Db2 for z/OS Version 9 and earlier server, use only the characters A-Z and 0-9 and the underscore (_) or period (.).

You must set the ClientApplicationName keyword before the start of a transaction. Changes to the ClientApplicationName keyword after the start of a transaction do not take effect until the start of the next transaction.

For connection to Db2 for z/OS servers, the ClientApplicationName keyword is replayed upon connection failover when the automatic client reroute (ACR) feature and the workload balance (WLB) feature are enabled.

A client sends the default client information register values to the Db2 for z/OS server when they are not explicitly set by the user. The default CURRENT CLIENT_APPLNAME special register value is the current process name. The SQLGetConnectAttr() function and the sqleqryi API can return the default value only when the enableDefaultClientInfo keyword is set to True in the IBM data server driver configuration file.