> For the complete documentation index, see [llms.txt](https://docs.e6data.com/query-engine/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.e6data.com/query-engine/guides/querying/run-queries-and-view-results.md).

# Run queries and view results

Run SQL in the e6data Query Editor, track query status, view and export results, inspect execution details, and preview data.

This page covers running queries in the Query Editor and working with their results. For the editor itself - tabs, formatting, find & replace, and the Schema Explorer - see [Query editor](/query-engine/guides/querying/query-editor.md).

## Run a query

Before running, set the **Catalog**, **Database**, and **Cluster** in the Query Action Bar above the editor. Then:

* Click **Run**, or press `Cmd/Ctrl + Enter`.
* **Run selected statements:** select the text of one or more statements and click **Run** - only the highlighted statements execute.
* **Multiple statements:** separate statements with semicolons (`;`); the editor runs them sequentially.
* **Stop a query:** while it runs, the **Run** button becomes **Cancel** - click it (or press `Cmd/Ctrl + Esc`).

{% hint style="info" %}
If the selected cluster is suspended, you're asked to confirm before it resumes.
{% endhint %}

### Set a default row limit

Setting a limit prevents accidentally running an unbounded query, which can drive up cost. Use the dropdown next to **Run**:

| Option                | Behavior                            |
| --------------------- | ----------------------------------- |
| NO LIMIT              | Runs until all results are returned |
| LIMIT 10 / 100 / 1000 | Stops after the first N rows        |

The Query Editor displays only the first **10,000 rows** - see [Working with large result sets](#working-with-large-result-sets) for more.

## Query status

As a query runs, its status moves through: **Connecting** → **Planning** → **Executing** → **Fetching result** → **Success** (or **Failed** on error).

## The results pane

The Results Pane appears below the editor after a run.

* **Single statement:** a single results table, with a summary bar showing **Execution Time**, **Row Count**, and **Query Status**.
* **Multiple statements:** the pane splits into a **query list** (one row per statement, with status, query text, and row count) and a **results** view for the selected statement.

### Execution details

Open a query's execution details for a full breakdown: final status, the executed SQL, rows returned and wall time, an overview (Query ID, Run By, cluster name and size), and a **Total Elapsed Time** bar split into **planning**, **queueing**, and **execution** time, plus **result fetching time** by the client.

### Query execution plan

Click **Show Execution Plan** to open the **Query Profile** - a visual map of how the engine ran your query. Review the most expensive nodes and each step's cost percentage, and use the zoom controls to navigate. Click **Hide Execution Plan** to return to the results.

## Results output

* **Copy cell data** - select a cell to view and copy its value (handy with large result sets).
* **Export results as CSV** - select **Export Result CSV** in the Results Pane; a progress bar shows large downloads.

### Working with large result sets

The browser displays only the first **10,000 rows**. For more:

* Use an [external connector](/query-engine/developers/connecting-to-the-engine.md) to access the full result set.
* Use [`COPY INTO`](/query-engine/reference/sql-reference/sql-commands/copy-into.md) to unload a large result set to your cloud object storage.

## Data preview

Data Preview returns the first 10 rows of a table or column for a quick look before you write a query. In the Schema Explorer, hover over a table or column, click the kebab (⋮), and select **Data Preview** - a new tab opens with the sample rows.

## Cross-catalog and cross-schema queries

You can combine data from different schemas and catalogs in a single query for a unified view of your data. Fully qualify each table with its catalog, schema, and table name:

```sql
SELECT column1, column2
FROM catalog_name.schema_name.table_name;
```

`catalog_name` is the name you gave the catalog when you created it in e6data. For Unity catalogs, it's the catalog created under Unity in Databricks.

## See also

* [Query editor](/query-engine/guides/querying/query-editor.md) - the editor, tabs, and Schema Explorer.
* [Query history and saved queries](/query-engine/guides/querying/query-history-and-saved-queries.md)
* [COPY INTO](/query-engine/reference/sql-reference/sql-commands/copy-into.md) - unload large results to storage.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.e6data.com/query-engine/guides/querying/run-queries-and-view-results.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
