> ## Documentation Index
> Fetch the complete documentation index at: https://docs.narrative.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Write Your First Query

> Create a filtered dataset using Query Builder in Data Studio

In this tutorial, you'll use Query Builder to create a filtered dataset from your data. Query Builder provides a visual interface for selecting data sources, choosing output fields, and applying filters—no code required.

<iframe src="https://demo.arcade.software/sNYnCk18POICs1tWZ54L?embed&embed_mobile=tab&embed_desktop=inline&show_copy_link=true" title="Create a filtered dataset in Data Studio using Query Builder" frameBorder="0" loading="lazy" allowFullScreen allow="clipboard-write" style={{ width: '100%', aspectRatio: '16/9' }} />

<Info>
  This tutorial is part of the First Steps series. Complete [Normalize with Rosetta Stone](/getting-started/normalize-data) before starting.
</Info>

## Prerequisites

* A Narrative I/O account
* At least one dataset in My Data

## What you'll learn

* How to access Data Studio
* How to use Query Builder to select data sources
* How to choose output fields
* How to add filters to narrow your data
* How to create and save a dataset

***

## Steps

<Steps>
  <Step title="Open Data Studio">
    From the navigation menu, go to **My Data** to view your available datasets. Then navigate to **Data Studio** to start creating a new dataset with Query Builder.
  </Step>

  <Step title="Add a data source">
    In Query Builder, click **Add** under **Sources** to choose where your dataset should pull data from. Select **My Data** as your source, then pick the dataset you want to work with. This dataset becomes the foundation for your filtered output.
  </Step>

  <Step title="Configure output fields">
    Click **Add** under **Output** to control which columns appear in the final dataset. Click **Add field** to select each column you want to include. Choose the fields that are relevant to your use case—these might include identifiers, timestamps, or any attributes you need for analysis.

    After selecting your fields, click **Continue** to confirm your output configuration.
  </Step>

  <Step title="Add a filter">
    Click **Add** under **Filter** to narrow your dataset to specific records. Choose a field to filter on, then select an operator (such as "Is greater than" or "Equals") and provide a value.

    For date fields, you can use the calendar picker to select a specific cutoff date. Click **Add** to apply the filter condition, then confirm to finalize your filter logic.
  </Step>

  <Step title="Create the dataset">
    Once your sources, outputs, and filters are configured, click **Create dataset**. Enter a unique name that makes your dataset easy to find and reference later. Click **Save** to generate the dataset from your query configuration.

    Your new filtered dataset is now available in My Data for use in analysis, exports, or collaborations.
  </Step>
</Steps>

***

## Next steps

<CardGroup cols={2}>
  <Card title="Filtering Data" icon="filter" href="/guides/nql/filtering-transforming">
    Learn to filter and transform your data
  </Card>

  <Card title="NQL Syntax Reference" icon="code" href="/nql/general/syntax">
    Explore the complete query syntax
  </Card>

  <Card title="Create a Materialized View" icon="layer-plus" href="/guides/nql/creating-materialized-views">
    Save query results for recurring use
  </Card>
</CardGroup>
