# Get started with the Ads Data Hub web UI

You can use the web UI in Ads Data Hub to do many of the same tasks as you would using the API. This guide shows how write a query that measures your total Campaign Manager 360 Data Transfer impressions from scratch, test it, and then run it.

> [!IMPORTANT]
> **Key Point:** You can substitute `cm_dt_impressions` with a different table to see impressions from other datasets, such as `google_ads_impressions`.

## Write your query

1. Navigate to the **Queries** tab.
2. Click **+ Create query** to open the query editor.
3. Click **Blank**.
4. In the query editor:

   1. Give your query a name.
   2. Paste in the following SQL:

       SELECT
         COUNT(*) AS impressions
       FROM adh.cm_dt_impressions
       ;

5. Save your query.

## Test your query using the sandbox

> [!NOTE]
> **Note:** You should test your queries using the sandbox role before running them on production data. This can help you find problems faster.

1. Navigate to the **Queries** tab in Ads Data Hub.
2. Click the name of the query you wrote earlier.
3. Click **Run** in the upper left corner of the editor.
4. Select **ADH Sandbox Customer** from the **Ads data from** dropdown.
5. Specify where your query results should be written in the **Destination table** field.
6. Select start and end dates between 2018-08-18 00:00:00 and 2018-09-17 23:59:59. We recommend using the auto-populated 30-day range.
7. Click **Start**.

After the query finishes running, open the results in [BigQuery](https://bigquery.cloud.google.com/). You should see a table that looks something like this:

| Row | impressions |
|---|---|
| 1 | 388204742 |

Once you're satisfied with the results of your test query, you're ready to run it on real data.

## Run your query in Ads Data Hub

After testing your query using the sandbox role, you're ready to run it on real data.

1. Navigate to the **Queries** tab in Ads Data Hub.
2. Click the name of the query you want to run.
3. Click **Run** .
   - The expected number of bytes that the query will use shows at the top of the page.
4. Select an ID in the **Ads data from** field. This should be the account ID associated with the ads data you want to query. (If you would like to query sandbox data, select **ADH Sandbox Customer**.)
5. If using a match table, select the match table in the **Match table from** field.
6. Select the privacy mode. [Learn more about privacy
   modes](https://developers.google.com/ads-data-hub/marketers/guides/privacy-checks#privacy_modes).
7. Specify where your query results should be saved in the **Destination
   table** field.
8. Enter start and end dates to determine the date range of your query.
9. Enter a time zone. This should match the time zone of the buying door.
10. Optional: Enter values for any parameters.
11. Click **Run**.