Refreshing Analytical Views

To ensure valid results, perform these steps:

  1. Check the state of an analytical view by running the following command:

    show analytical views;
  2. If the state of the views is either STALE or UNUSABLE, refresh the analytical view:
    refresh analytical view events_aview;
  3. If the state of the analytical view is INVALID, recreate the analytical view after correcting its definition:
    create analytical view events_aview
       stored as parquet
       as (select   count(*), platform, sdk_version
           from     events
           group by platform, sdk_version);