rw-book-cover

Metadata

Highlights

For very large tables in your database, Looker developers can create smaller aggregate tables of data, grouped by various combinations of attributes. The aggregate tables act as roll-ups or summary tables that Looker can use for queries whenever possible, instead of the original large table (View Highlight)

The Explore query’s filters reference fields that are available as dimensions in the aggregate table, or each of the Explore query’s filters matches a filter in the aggregate table (View Highlight)

To be used for an Explore query, an aggregate table must have all the dimensions and measures needed for that Explore query, including the fields used for filters in the Explore query. If an Explore query contains a dimension or measure that is not in an aggregate table, Looker can’t use the aggregate table and will use the base table instead. (View Highlight)

In the case of measures with type: average, aggregate awareness is supported because Looker uses sum and count data to accurately derive average values from aggregate tables. (View Highlight)

In general, distinct counts aren’t supported with aggregate awareness because you can’t get accurate data if you try to aggregate distinct counts (View Highlight)

For example, if you are counting the distinct users on a website, there may be a user who came to the website twice, three weeks apart. If you tried to apply a weekly aggregate table to get a monthly count of distinct users on your website, that user would be counted twice in your monthly distinct count query, and the data would be incorrect. (View Highlight)