ID EN
Information Functions

CONNECTION_ID()

MySQL 8.4 🇮🇩 Bahasa Indonesia

Mengembalikan ID koneksi (ID thread) untuk koneksi. Setiap koneksi memiliki ID yang unik di antara kumpulan klien yang terhubung saat ini.

Syntax

MYSQL
SELECT CONNECTION_ID();
23786

Contoh

Example

The value returned by CONNECTION_ID() is the same type of value as displayed in the ID column of the Information Schema PROCESSLIST table, the Id column of SHOW PROCESSLIST output, and the PROCESSLIST_ID column of the Performance Schema threads table.

MYSQL
SELECT CONNECTION_ID();
23786