Admin settings - Usage

The Usage page is a Looker-created dashboard that presents usage information about your Looker instance. Admins can use the data to better understand how their users utilize the application. To view the Usage page, from the Server section of the Admin menu, select Usage.

Usage dashboard

Access the Usage dashboard from the Admin panel under the Server section.

You can download or schedule the Usage dashboard just as any other dashboard.

You can also drill down on data points on the Usage dashboard.

Query by Source tile

The Query by Source tile, which is located at the top of the Usage page, includes information about the number of queries run from different sources within Looker. These are the possible sources:

  • API (version number): Queries that came from the Looker API for the instance.
  • Dashboard: Queries relating to tiles present on a dashboard.
  • Dashboard Prefetch: Queries from the API to pre-run a dashboard.
  • Explore: Queries associated with running Explores.
  • Other: Queries from sources that do not fall into any other category.
  • Private Embed: Queries that were initiated by a private embed context.
  • Public Embed: Queries run from content that is accessed via public URL.
  • Query: Short for source_query, queries generated by Looker's internal i__looker database.
  • Renderer: Queries relating to the generation of images (.png and .pdf) for scheduled items and downloads.
  • SQL Runner: Queries that are run directly in the SQL Runner.
  • Saved Look: Queries associated with Looks.
  • Scheduled Task: Queries run by Looker when it generates a Look or dashboard for delivery.
  • Suggest Filter: Queries generated when users click on a filter that generates suggestions. In this case, Looker runs a SELECT DISTINCT on the filtered field to find the suggestions to surface to the user.

Context comments for SQL queries

Looker adds a unique comment to the beginning of each SQL query. The comments are added to queries from Explores, SQL Runner, the API, and filter suggestions. Context comments are automatically included.

Context comments on Google BigQuery connections are disabled by default because context comments invalidate Google BigQuery's ability to cache and can negatively impact cache performance. You can enable context comments for a BigQuery connection by enabling the Disable Context toggle on the Connection Settings page for the connection. See the Google BigQuery documentation page for more information.

Context comments are added in the following format:

-- Looker Query Context '{ "user_id":<user ID>,"history_slug":<history slug>,"instance_slug":"<Looker instance number>}'

The comments provide the following information:

  • user_id: The unique identifier for each user on the Looker instance. You can match this user ID to the user IDs on the Users page in the Admin menu.

  • history_slug: The unique identifier for each query that is run on the database by the Looker instance.

  • instance_slug: The ID number of the Looker instance that issued the query. Looker support can use this information to help you troubleshoot, if necessary.

The context comments are added to outgoing SQL commands right before the SQL is sent to the database. This prevents the comments from affecting the caching of Looker queries, but it also means that you cannot see the added comments in most places in Looker (such as the Queries page or i__looker).

Instead, you'll see these comments in your database query logs.