Dear @dba_S4dscjz
Thank you so much i really appreciate your help, it worked,
To log username i did a trick, instead of connection i used general, it’s drawback it’s logging log for every event but fine as instead of only connection id username is imp for me,
here is the output of log
{
“timestamp”: “2025-05-17 10:17:11”,
“id”: 40,
“class”: “general”,
“event”: “log”,
“connection_id”: 11,
“account”: { “user”: “root[root] @ localhost ”, “host”: “localhost” },
“login”: { “user”: “root[root] @ localhost ”, “ip”: “”, “proxy”: “” },
“general_data”: { “status”: 0 }
},
{
“timestamp”: “2025-05-17 10:17:11”,
“id”: 41,
“class”: “query”,
“event”: “query_start”,
“connection_id”: 11,
“query_data”: {
“query”: “create database ssr”,
“status”: 0,
“sql_command”: “create_db”}
},
{
“timestamp”: “2025-05-17 10:17:11”,
“id”: 42,
“class”: “query”,
“event”: “query_status_end”,
“connection_id”: 11,
“query_data”: {
“query”: “create database ssr”,
“status”: 0,
“sql_command”: “create_db”}
},