Firebird Documentation Index → Firebird 2.0 Language Ref. Update → Context variables → CURRENT_CONNECTION |
Available in: DSQL, PSQL
Added in: 1.5
Description: CURRENT_CONNECTION
returns a unique identifier for the current connection.
Type: INTEGER
Examples:
select current_connection from rdb$databaseexecute procedure P_Login(current_connection)
The value of CURRENT_CONNECTION
is stored on the database header page and reset upon restore. Since the engine itself is not interested in this value, it
is only incremented if the client reads it during a session. Hence it is only useful as a unique identifier, not as an indicator
of the number of connections since the creation or latest restoration of the database. Please note that this will change in
Firebird 2.1.
Firebird Documentation Index → Firebird 2.0 Language Ref. Update → Context variables → CURRENT_CONNECTION |