Datagroups let you specify query caching policies and triggers for rebuilding PDTs. If you have permissions to access the Datagroups page in the Database section of the Admin menu, you’ll see a summary of datagroups defined in a model for which they have data access:
The Datagroups page provides the following information for each datagroup:
|Name||The name of the datagroup, which you define in the model file.|
|Label||Specifies an optional datagroup label, which you define for the
|Connection||The database connection of the datagroup.|
|Model||The LookML model where the datagroup is defined. (Click the LookML button to open the LookML model file.)|
|Type||The datagroup’s trigger type, such as
|Description||Specifies an optional datagroup description, which you define for the
|Actions||Actions you can take on the datagroup (see below).|
Depending on the datagroup status, the following detailed information may also be displayed under the name:
- Status shows the current status of the datagroup. The status is also indicated by the colored dots next to each line for the datagroup:
- Green — The datagroup is in a ready state.
- Orange — The datagroup is in the triggered state, or the datagroup was recently deployed to production and the trigger check cycle has not yet started.
- Red — The most recent trigger check errored, or there is an error with the datagroup’s LookML. You can click the LookML button to open the LookML model file.
- Trigger value shows the result of the
sql_triggerquery that triggered the datagroup. In the example above, the SQL trigger for the
orders_datagroupis based on the maximum ETL log ID. The Trigger value shows the new ETL log ID that triggered the datagroup: 284183.
- Triggered since is displayed for datagroups in the triggered state to show how long it has been since the datagroup was triggered. This provides information on how long it is taking to rebuild PDTs and run the queries that triggered by the datagroup. Once all PDTs are rebuilt, the datagroup’s color will update to green to indicate that the datagroup is ready, and after several minutes the Triggered since information will disappear from the page since the datagroup is complete.
- Trigger error provides error information for the datagroup triggers. In the example above, the
user_informationdatagroup has a syntax error in its SQL trigger. When you see an error like this, you can click the LookML button to open the LookML model file and correct the SQL syntax.
- Trigger last checked shows the last time that the datagroup’s
sql_triggerSQL query was run. If the value returned by the query is different next time, that triggers the datagroup.
- Cache reset at shows the time when the cache was last reset (when the cached data in the datagroup was last invalidated).
Depending on your permissions, you can perform the following actions on datagroups from the Datagroups Admin page:
- Click on the LookML button to open the LookML model file where the datagroup is defined.
- Select Reset Cache from the gear menu to immediately invalidate the cached results for all Explores using that datagroup.
- Select Trigger Datagroup from the gear menu to invalidate the cached results for all Explores and rebuild all PDTs using that datagroup. The PDT rebuild will begin based on the next time specified in the connection’s PDT And Datagroup Maintenance Schedule field, such as every five minutes. Any scheduled data deliveries of Looks, dashboards, legacy dashboards, and LookML dashboards that use the datagroup as a trigger will be sent when the triggered datagroup reaches the ready state.