APPLICATION_ID scalar function
The APPLICATION_ID function returns
the application ID of the current connection.
The data
type of the result is VARCHAR(128).
The value returned by the function is unique within a 100-year interval and valid only for the duration of the connection established before calling the function.
Note: This scalar function has been deprecated and replaced by the MON_GET_APPLICATION_ID scalar function.
Syntax
The schema is SYSFUN.
Authorization
One of the following authorities
is required to execute the function:
- EXECUTE privilege on the function
- DATAACCESS authority
- DBADM authority
- SQLADM authority
Default PUBLIC privilege
In a non-restrictive database, EXECUTE privilege is granted to PUBLIC when the function is automatically created.
Example
SELECT APPLICATION_ID() AS APPL_ID FROM SYSIBM.SYSDUMMY1