This is an automated email from the ASF dual-hosted git repository. bridgetb pushed a commit to branch gh-pages in repository https://gitbox.apache.org/repos/asf/drill.git
The following commit(s) were added to refs/heads/gh-pages by this push: new b3428b3 edits b3428b3 is described below commit b3428b331f0618e52db205875e3abeb796bae286 Author: Bridget Bevens <bbev...@maprtech.com> AuthorDate: Thu Apr 18 12:33:10 2019 -0700 edits --- .../030-planning-and-exececution-options.md | 6 +++--- _docs/sql-reference/sql-commands/084-limit-clause.md | 18 +++++------------- 2 files changed, 8 insertions(+), 16 deletions(-) diff --git a/_docs/configure-drill/configuration-options/030-planning-and-exececution-options.md b/_docs/configure-drill/configuration-options/030-planning-and-exececution-options.md index b10816b..0d8a564 100644 --- a/_docs/configure-drill/configuration-options/030-planning-and-exececution-options.md +++ b/_docs/configure-drill/configuration-options/030-planning-and-exececution-options.md @@ -38,9 +38,9 @@ See [Querying the Options Table]({{site.baseurl}}/docs/querying-system-tables/#q ### Setting Options from the Drill Web UI -When Drill is running, you can access the Drill Web UI at `http://<drill-hostname>:8047/`. The Drill Web UI has an Options button located in the upper right corner that you can click to display an Options page. The Options page lists all the Drill options that you can set. When you set options from this page, you are setting the options at the system level. To override an option for the duration of a session, set the option from the Drill shell using the SET command. +When Drill is running, you can access the Drill Web UI at `http://<drill-hostname>:8047/`. The Drill Web UI has an Options button located in the upper right corner that you can click to display an Options page. -![](https://i.imgur.com/WMij8gQ.png) +The Options page lists all the Drill options that you can set at the system level. To override an option for the duration of a session, set the option from the Drill shell using the SET command. Starting in Drill 1.15, the Options page includes the following enhancements: @@ -91,7 +91,7 @@ Issuing the query after setting the `web.display_format.timestamp` option to the 2008-02-23 12:23:34.00 -##Limiting the Number of Rows Returned for Result Sets +##Setting an Auto Limit on the Number of Rows Returned for Result Sets The `exec.query.max_rows` option, introduced in Drill 1.16, automatically limits the number of rows that Drill returns from a result set. When you configure a limit, the limit is automatically applied by Drill when you run a query. You do not need to include the LIMIT clause. Configuring a limit on results reduces the amount of processing and streaming work for the web server when using the Drill WEb UI. The default setting for `exec.query.max_rows` is 0, which indicates no limit; queries will return all results. An administrator can modify the exec.query.max_rows setting at the system level (setting persists across restarts) from the Options page in the Drill Web UI or using the ALTER SYSTEM command. Alternatively, the option can be set at the session level (valid for a user session only) using the SET command or from SQLLine. diff --git a/_docs/sql-reference/sql-commands/084-limit-clause.md b/_docs/sql-reference/sql-commands/084-limit-clause.md index c0f9212..8f1f4f5 100644 --- a/_docs/sql-reference/sql-commands/084-limit-clause.md +++ b/_docs/sql-reference/sql-commands/084-limit-clause.md @@ -1,9 +1,11 @@ --- title: "LIMIT Clause" -date: 2018-08-05 04:52:50 UTC +date: 2019-04-18 parent: "SQL Commands" --- -The LIMIT clause limits the result set to the specified number of rows. You can use LIMIT with or without an ORDER BY clause. +The LIMIT clause limits the result set to the specified number of rows. You can use LIMIT with or without an ORDER BY clause. + +Starting in Drill 1.16, you can configure an automatic limit on the number of rows returned from a result set. See [Setting an Auto Limit on the Number of Rows Returned for Result Sets]({{site.baseurl}}/docs/planning-and-execution-options/#setting-an-auto-limit-on-the-number-of-rows-returned-for-result-sets). ## Syntax @@ -72,23 +74,13 @@ Hive has a list of functions with return type NVARCHAR, which the query planner **Unsupported Operators and Functions** LIMIT 0 optimizations do not work for queries with the UNION [ALL] set operator or the following complex functions: - - KVGEN or MAPPIFY - FLATTEN - CONVERT_FROMJSON - CONVERT_TOJSON - CONVERT_TOSIMPLEJSON - CONVERT_TOEXTENDEDJSON -- AVG (window function) - - - - - - - - - +- AVG (window function) ## Examples The following example query includes the ORDER BY and LIMIT clauses and returns the top 20 sales totals by month and state: