Step 2: Query without data filters - Amazon Lake Formation
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).

Step 2: Query without data filters

After you set up the environment, you can query the product reviews table. First query the table without row-level access controls to make sure you can see the data. If you are running queries in Amazon Athena for the first time, you need to configure the query result location.

Query the table without row-level access control
  1. Sign into Athena console at https://console.amazonaws.cn/athena/ as the DatalakeAdmin user, and run the following query:

    SELECT * FROM lakeformation_tutorial_row_security.amazon_reviews LIMIT 10

    The following screenshot shows the query result. This table has only one partition, product_category=Video, so each record is a review comment for a video product.

  2. Next, run an aggregation query to retrieve the total number of records per marketplace.

    SELECT marketplace, count(*) as total_count FROM lakeformation_tutorial_row_security.amazon_reviews GROUP BY marketplace

    The following screenshot shows the query result. The marketplace column has five different values. In the subsequent steps, you will set up row-based filters using the marketplace column.