Query count by user

Hello,

How to get the details of a query executed by a memsql user?. Looking for a log file or command or table which contains all the details about all queries executed by a user.

Thanks in advance

Outside of audit logging (https://docs.memsql.com/v7.1/guides/security/audit/audit-logging/), I don’t think we have a way of showing the queries executed by a particular user.

You can find historical statistics about queries executed via information_schema.plancache or show plancache (https://docs.memsql.com/v7.1/reference/sql-reference/show-commands/show-plancache/), but this won’t tell you which user(s) have run the query. You can see which users are running active queries via information_schema.processlist (while the query is running).