> For the complete documentation index, see [llms.txt](https://docs.nuvolos.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.nuvolos.com/reference/data-storage/build-queries.md).

# Query Builder

Nuvolos provides an easy-to-use query builder for creating and running SQL queries. Open the Query Builder by clicking a table name and selecting Query table, or by clicking the Query button next to the table name.

## Column selection

Choose which columns to include:

* Click Select all for all columns, or click individual column names.
* Selected columns appear in the Selected columns list on the right.
* Remove individual columns with the red clear button, or use Remove all to clear the selection.

{% hint style="warning" %}
At least one column must be selected in order to move to the next step!
{% endhint %}

## Filters

You can add conditions to filter the selected columns and return only rows that meet specific criteria. To add a filter, click Add filter and choose one of the selected columns. To remove a filter, click the red cross button next to it.

* FLOAT or NUMERIC - For NUMERIC and FLOAT columns, all filter types are available, including equal, not equal, greater than, and less than. You can also use the in filter to upload a file containing the values to filter by. FLOAT and NUMERIC filters can only take numbers as filtering values.
* **VARCHAR (string)** - For VARCHAR or string columns, you can use non-order-based filters such as equal and not equal, but not order-based filters such as greater than or less than.
* **DATE, TIME, DATETIME** - For date and time columns, filtering is done using date and time pickers. These allow you to select a specific date, time, or a range of dates and times.

{% hint style="info" %}
To select a past date, use the top bar of the date picker. Click the month and year displayed at the top of the calendar once to switch to month selection, then click it again to switch to year selection.
{% endhint %}

{% hint style="success" %}
Adding filters is optional, but all added filters must be valid to proceed to the next step.
{% endhint %}

## Aggregation functions

Aggregation functions let you group values in the selected columns and calculate summary results based on those groups.&#x20;

* Click **Add aggregation function** to add functions.
* Click **Add aggregation filter** to filter the aggregated results.

For example, you can group rows by the distinct values in FLOAT\_COLUMN and count how many times each value appears. You can then add an aggregation filter to return only results where the count is greater than 100.

{% hint style="success" %}
Aggregation is optional; all added aggregators and filters must be valid to proceed.
{% endhint %}

## Sort conditions

You can add one or more sorting conditions for the selected columns or for columns created by aggregation functions.

{% hint style="success" %}
Sorting is optional.
{% endhint %}

## Limit condition

The Limit condition specifies the maximum number of rows returned by the query and is required.

## Review and submit

The final step is to review the SQL query. Then:

* **Submit for data export** - executes the query and downloads the results as a zipped CSV file.
* **Run from Application** - generates a code snippet for running the query from an Application. Select the programming language.


---

# 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.nuvolos.com/reference/data-storage/build-queries.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.
