---
title: Build a SQL exploration
slug: analytics/docs/Xv0b-build-a-sql-exploration
docTags: 
createdAt: 2026-07-20T15:45:07.621Z
---

To demonstrate the use of the SQL explorer for ad hoc analysis, consider a scenario in which you need to locate users who use the iOS platform along with their name and subscription ID.

To build such an exploration, follow these steps:

1. Go to **+ > SQL**.
2. Add the basic SQL commands in the query builder to initiate the query, and double-click the **name**, **platform**, and **subscription\_id** columns to add them to the query.
3. Double-click the **Users** dataset to add it to the query.
4. Complete the query by double-clicking the **platform** column in the catalog and adding a condition to filter out users who use the **iOS** platform. Your query will look like this:
   *select "name", "platform", "subscription\_id" from "Data.Users" where "platform"= 'iOS'*
5. Click **Run**.
6. Name the exploration and click **Save**.

![opti-sql-2.png](https://api.archbee.com/api/optimize/BrbvVORKJ5iIeSMZye5kI/Uwe4E9bqt_GycEXnueIo_-20260720-144900.png)
