VeloDB Cloud 26.x·Apache Doris 4.x (≤ 4.0 supported)·"Since X.Y" tags refer to Doris versionsversion mapping →
SESSION_USER
Description
Get the current username and IP of Doris connection, compatible with MySQL protocol.
Syntax
SESSION_USER()
Return Value
Returns the current username and IP Doris is connected to.
Format:<user_name>@<ip>
Examples
select session_user();
+----------------------+
| session_user() |
+----------------------+
| 'root'@'10.244.2.10' |
+----------------------+