A user or client application can query a global variable to find the property and processing values that affect that client connection.
A global variable represents one of the following:
A configuration property value
Information about the processing state of the current connection
The current value for a configuration property resulting from a set statement
A client application can query all global variables regardless of the SQL transformation mode in effect. However, the global variable statement must be the only statement in a request. For more information about SQL transformation modes, see “SQL transformation modes”.
Global variables are preceded by two “at” (@@) symbols and are not case sensitive.
To query a global variable, issue a SQL statement in this form:
select @@variable_name
where variable_name is the name of the relevant global variable.
The access service returns the configuration property value or the processing information for the current connection.
For example, the SQL statement select @@Allocate returns the Allocate configuration property value of either connect or request.