Skip to main content
Version: V1.0.0

CONNECTION_ID

Declaration

CONNECTION_ID()

Description

This function returns the Client Session ID of the current session. This ID uniquely identifies the session on the client.

Example

Get the Client Session ID of the current session.

SELECT CONNECTION_ID() AS Client_Session_ID;

The return result is as follows:

+-------------------+
| Client_Session_ID |
+-------------------+
| 3221488032 |
+-------------------+
1 row in set (0.001 sec)