I want to know:
- how to get the number of queries a user makes per month in BigQuery?
- how many queries a specific user makes, how many per year.
I found the command
bq ls -j
with that bring the number of jobs and with the comand bq show get the detail, but it does not bring me all the elements that I need, I would like to know if someone knows another way to achieve this.
You need to enable Audit Logs, and create a Sink for Bigquery.
Then you can write a query that uses for
protoPayload.methodName
column one of thegoogle.cloud.bigquery.v2.JobService.Query
valuesExample: Bytes processed per user identity