Create a dataset with Amazon IoT SiteWise data (Console) - Amazon IoT Analytics
Services or capabilities described in Amazon Web Services documentation might vary by Region. To see the differences applicable to the China Regions, see Getting Started with Amazon Web Services in China (PDF).

Create a dataset with Amazon IoT SiteWise data (Console)

Use these steps to create a dataset in the Amazon IoT Analytics console for your Amazon IoT SiteWise data.

To create a dataset
  1. In the, on the left navigation pane, choose Datasets.

  2. On the Create dataset page, choose Create SQL.

  3. On the Specify dataset details page, specify the details of your dataset.

    1. Enter a name for your dataset.

    2. For Data store source, choose the unique ID that identifies your Amazon IoT SiteWise data store.

    3. (Optional) For Tags, add one or more custom tags (key-value pairs) to your dataset.

  4. Use SQL expressions to query your data and answer analytical questions.

    1. In the Author query field, enter a SQL query that uses a wildcard to display up to five rows of data.

      SELECT * FROM my_iotsitewise_datastore.asset_metadata LIMIT 5

      For more information about supported SQL functionality in Amazon IoT Analytics, see SQL expressions in Amazon IoT Analytics. Or, see Tutorial: Query Amazon IoT SiteWise data in Amazon IoT Analytics for examples of statistical queries that can provide insight to your data.

    2. You can choose Test query to validate that your input is correct, and to display the results in a table following the query.


      Because Amazon Athena limits the maximum number of running queries, you should limit your SQL query to a reasonable size so that it does not run for an extended period.

  5. (Optional) When you create dataset contents using data from a specified time frame, some data might not arrive in time for processing. To allow for a delay, you can specify an offset, or delta. For more information, see Getting late data notifications through Amazon CloudWatch Events.

    After configuring a data selection filter on the Configure data selection filter page, choose Next.

  6. (Optional) On the Set query schedule page, you can schedule this query to run regularly to refresh the dataset. Dataset schedules can be created and edited at any time.


    Data from Amazon IoT SiteWise ingests into Amazon IoT Analytics every six hours. We recommend selecting a frequency that is six hours or more.

    Choose and option for Frequency and then choose Next.

  7. Amazon IoT Analytics will create versions of this dataset content and store your analytics results for the specified period. We recommend 90 days, however you can opt to set your custom retention policy. You may also limit the number of stored versions of your dataset content.

    After selecting your options on the Configure the results of your dataset page, choose Next.

  8. (Optional) You can configure the delivery rules of your dataset results to a specific destination, such as Amazon IoT Events.

    After selecting your options on the Configure dataset content delivery rules page, choose Next.

  9. Review your choices and then choose Create dataset.

  10. Verify that your new dataset appears on the Datasets page.