# Data Explorer

Paradime IDE's Data Explorer provides real-time data preview capabilities for your dbt™ models and SQL queries, allowing you to validate your transformations without running a full dbt™ compile.

### How It Works

Click the Data Explorer Tab in the [Command Panel](https://docs.paradime.io/app-help/documentation/code-ide/command-panel). Here you can:

* Preview Data (View model results)
* Download results as CSV
* Preview compiled SQL
* Preview specific SQL segments

{% @arcade/embed url="<https://app.arcade.software/share/hW14LmU2pQ88UZUlJ6Wo>" flowId="hW14LmU2pQ88UZUlJ6Wo" %}

***

### Compile & preview using production state (Defer to Production)

If you enable **Defer to Production** in the IDE, Data Explorer will compile and preview your models using the **production state** (the latest `manifest.json` from the production schedule you selected).

This is useful when you want to:

* Validate changes to a downstream model **without** rebuilding all upstream models in your dev schema.
* Preview results against production-like upstream relations while still iterating in development.

{% hint style="info" %}
When Defer to Production is enabled, both Data Explorer actions (**Preview Data** and **Compiled SQL**) will automatically defer to the selected production manifest/state.

For setup requirements and deeper details on how `--defer` works, see [Using Defer to Production in Paradime](https://docs.paradime.io/app-help/concepts/paradime-fundamentals/dbt-tm-defer-to-production) and ["Defer to Production" configuration](https://docs.paradime.io/app-help/bolt/managing-schedules/schedule-configurations#defer-to-production-configuration).
{% endhint %}

***

### Previewing Data

1. Open any SQL file in the editor
2. Click the Data Explorer icon in the command panel
3. Optional: Change the query row limit to your desired value (anywhere between 1-1000)
4. Click "Preview Data" to see your model's results
5. Review the compiled SQL and data output
6. Optional: Download the data returned in the preview as a .csv, click "Download CSV"

<figure><img src="https://2337193041-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHET0AD04uHMgdeLAjptq%2Fuploads%2FEz7xztpIC61ayQwLVHWj%2Fimage.png?alt=media&#x26;token=7a0b9020-6686-44ab-87b5-e937d312a52a" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
By default, Paradime automatically adds a `LIMIT 100` to the data preview. You can change this limit anywhere between 1 - 1000 by editing the text box next to "Query Limit"
{% endhint %}

***

### Previewing Compiled SQL

1. Click the Data Explorer icon in the [command panel](https://docs.paradime.io/app-help/documentation/code-ide/command-panel)
2. Click "Compiled SQL" to see your model's results
3. Review the compiled SQL to understand how your SQL, jinja, and macros unfold

<figure><img src="https://2337193041-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHET0AD04uHMgdeLAjptq%2Fuploads%2FHrHWE2sPXzJlwsDi5QMj%2Fimage.png?alt=media&#x26;token=f8950884-8fa8-4ec9-9f15-b28e701a59cb" alt=""><figcaption></figcaption></figure>

***

### Preview Specific SQL Segments

To preview only a portion of your model (like a CTE or subquery):

1. Highlight the desired SQL segment in your file
2. Click the Data Explorer icon in the command panel
3. Click "Preview Data" to see results for just that segment

<figure><img src="https://2337193041-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHET0AD04uHMgdeLAjptq%2Fuploads%2FoIppJyTS6HUlJIgRr7ZN%2Fimage.png?alt=media&#x26;token=f80af3f3-e0e9-4fad-9aaf-f8e060289454" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
This is useful for testing individual CTEs or subqueries before running your entire model.
{% endhint %}

***

### Related Resources

[**Scratchpad**](https://docs.paradime.io/app-help/documentation/code-ide/additional-features/scratchpad) - Need a space for SQL experiments? Scratchpad provides a temporary environment for testing SQL and dbt™ queries without affecting your project files. Learn more about writing and testing queries in a dedicated, persistent workspace.
