QUERY_AUDIT_LOG queries the audit log information of TDSQL Boundless databases. By default, it aggregates the audit logs from all Hyper Nodes.Field Name | Type | Description |
name | varchar(65535) | SQL statement type |
timestamp | timestamp | Statement execution time |
status | longlong | Statement execution status |
trans_id | longlong | Transaction ID to which the statement belongs |
tid | longlong | Thread ID of statement execution |
last_error_tdstore | varchar(65535) | Last error information related to TDStore |
proxy_executor | varchar(65535) | Proxy target node name |
user | varchar(65535) | Database username of the user who performed the operation |
host | varchar(65535) | Database server hostname |
client_host | varchar(65535) | Client hostname or IP address |
db | varchar(65535) | Name of the database involved in the operation |
affected_rows | longlong | Number of affected rows |
result_rows | longlong | Number of rows returned by the query result |
examined_rows | longlong | Number of rows scanned and examined |
in_tx | longlong | Whether executed within a transaction |
query_tc | double | Total query time |
lock_tc | double | Lock wait time |
rpc_tc | double | RPC call time |
tdstore_rpc_tc | double | TDStore RPC call time |
tdstore_lock_tc | double | TDStore lock wait time |
sqlsize | longlong | SQL statement size |
sqltext | varchar(65535) | SQL statement text |
sqldigest | varchar(65535) | SQL statement digest |
error_info | varchar(65535) | Detailed error information |
tdsql > SELECT * FROM INFORMATION_SCHEMA.QUERY_AUDIT_LOG WHERE name = 'Query' LIMIT 1\\G*************************** 1. row ***************************name: Querytimestamp: 2025-11-29 23:55:23status: 0trans_id: 0tid: 1048610last_error_tdstore:proxy_executor:user: tdsql3_sys_remotehost:client_host: 127.0.0.1:53360db: information_schemaaffected_rows: 0result_rows: 0examined_rows: 0in_tx: 0query_tc: 0.000076lock_tc: 0rpc_tc: 0tdstore_rpc_tc: 0tdstore_lock_tc: 0sqlsize: 14sqltext: SET NAMES utf8sqldigest:error_info:1 row in set, 1 warning (0.29 sec)
Was this page helpful?
You can also Contact sales or Submit a Ticket for help.
Help us improve! Rate your documentation experience in 5 mins.
Feedback