Skip to main content

CONNECTION_ID

Descriptionโ€‹

Get the connection number of the current sql client.

Syntaxโ€‹

CONNECTION_ID()

Return valueโ€‹

The connection number of the current sql client.

Examplesโ€‹

select connection_id();
+-----------------+
| connection_id() |
+-----------------+
| 549 |
+-----------------+

Enter to send ยท Shift+Enter for a new line