Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions docs-mintlify/reference/configuration/environment-variables.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -1531,6 +1531,27 @@ Queries with a `LIMIT` at or below that limit are not streamed.
| --------------- | ---------------------- | --------------------- |
| `true`, `false` | `false` | `false` |

## `CUBESQL_FAIL_ON_LIMITLESS_POST_PROCESSING`

If `true`, the [SQL API][ref-sql-api] rejects a query when part of it has to run outside
the data source over a Cube query that has no `LIMIT` of its own.

Such a query is capped at the maximum row limit set by
[`CUBESQL_NON_STREAMING_QUERY_MAX_ROW_LIMIT`](#cubesql_non_streaming_query_max_row_limit),
without any ordering. Sorting, filtering, or joining that capped result outside the data
source treats an arbitrary slice of the rows as if it were the whole population, so the
answer is wrong rather than merely short. The SQL API pushes these queries down to the
data source whenever it can; this option controls what happens when it cannot. Leave it
`false` to keep returning the truncated result, or set it to `true` to fail with an error
instead.

Queries that are streamed (see [`CUBESQL_STREAM_MODE`](#cubesql_stream_mode)) are never
capped, so this option has no effect on them.

| Possible Values | Default in Development | Default in Production |
| --------------- | ---------------------- | --------------------- |
| `true`, `false` | `false` | `false` |

## `CUBESQL_CUBE_SCAN_MAX_BATCH_ROWS`

Specifies the maximum number of rows in a single record batch produced when the
Expand Down
Loading
Loading