SQL Scalar Functions
CONNXCDD()
This function is used to retrieve the current CONNX data dictionary name.
Example: SELECT connxcdd()
CONNX_API_VERSION( [catalog_exp] )
This function is used to retrieve the version of the API protocol used to communicate between the client and the server. catalog_exp can optionally refer to the catalog name of the connection for which the build information will be returned. Information about the protocol API version can be useful during calls to CONNX Technical Support.
Example: SELECT connx_api_version( 'VSAM_SERVER' )
CONNX_SERVER_VERSION( [catalog_exp] )
This function is used to retrieve build number information of the specified CONNX Server. catalog_exp can optionally refer to the catalog name of the connection for which the build information will be returned. Information about build numbers can be useful during calls to CONNX Technical Support.
Example: SELECT connx_server_version( 'VSAM_SERVER' )
CONNX_VERSION()
This function is used to retrieve build number information of the CONNX Client. Information about build numbers can be useful during calls to CONNX Technical Support.
Example: SELECT connx_version()
DATABASE()
Returns the name of the current ODBC/JDBC data source. If a DSN-less connection is used, it returns an empty string.
Example: SELECT DATABASE() returns CONNX9SAMPLES32
GETCURSORNAME()
This function returns the SQL cursor name.
Example: SELECT GETCURSORNAME()
To embed it in a SELECT ... FOR UPDATE SQL statement, use the following syntax:
SELECT GETCURSORNAME(), CUSTOMERNAME FROM CUSTOMERS_TABLE WHERE CUSTOMERID = '12345' FOR
UPDATE OF CUSTOMERNAME
NTUSERNAME()
This function is used to retrieve the current user name.
Example: SELECT ntusername()
USER()
Returns the current CONNX user name.
Example: SELECT USER() returns NICKD (current user name)
XPUSERNAME()
This function is used to retrieve the fully qualified Windows user name for machines running Windows XP SP2 and above.
Example: SELECT xpusername()