forked from ClickHouse/ClickHouse
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
New topic in the docs "Permissions for queries" (ClickHouse#3616)
* Update of english version of descriprion of the table function `file`. * New syntax for ReplacingMergeTree. Some improvements in text. * Significantly change article about SummingMergeTree. Article is restructured, text is changed in many places of the document. New syntax for table creation is described. * Descriptions of AggregateFunction and AggregatingMergeTree are updated. Russian version. * New syntax for new syntax of CREATE TABLE * Added english docs on Aggregating, Replacing and SummingMergeTree. * CollapsingMergeTree docs. English version. * 1. Update of CollapsingMergeTree. 2. Minor changes in markup * Update aggregatefunction.md * Update aggregatefunction.md * Update aggregatefunction.md * Update aggregatingmergetree.md * GraphiteMergeTree docs update. New syntax for creation of Replicated* tables. Minor changes in *MergeTree tables creation syntax. * Markup fix * Markup and language fixes * Clarification in the CollapsingMergeTree article * DOCAPI-4821. Sync between ru and en versions of docs. * Fixed the ambiguity in geo functions description. * Example of JOIN in ru docs * Deleted misinforming example. * New topic 'Permissions for queries' * Fixes for docs consistency. * Self-targeting link.
- Loading branch information
Showing
12 changed files
with
64 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
<a name="permissions_for_queries"></a> | ||
|
||
# Permissions for queries | ||
|
||
Queries in ClickHouse can be divided into several groups: | ||
|
||
1. Read data queries: `SELECT`, `SHOW`, `DESCRIBE`, `EXISTS`. | ||
1. Write data queries: `INSERT`, `OPTIMIZE`. | ||
1. Change settings queries: `SET`, `USE`. | ||
1. [DDL](https://en.wikipedia.org/wiki/Data_definition_language) queries: `CREATE`, `ALTER`, `RENAME`, `ATTACH`, `DETACH`, `DROP` `TRUNCATE`. | ||
1. Particular queries: `KILL QUERY`. | ||
|
||
The following settings regulate user permissions for the groups of queries: | ||
|
||
- [readonly](#settings_readonly) — Restricts permissions for all groups of queries excepting DDL. | ||
- [allow_ddl](#settings_allow_ddl) — Restricts permissions for DDL queries. | ||
|
||
`KILL QUERY` performs with any settings. | ||
|
||
<a name="settings_readonly"></a> | ||
|
||
## readonly | ||
|
||
Restricts permissions for read data, write data and change settings queries. | ||
|
||
See [above](#permissions_for_queries) for the division of queries into groups. | ||
|
||
**Possible values** | ||
|
||
- 0 — All queries are allowed. Default value. | ||
- 1 — Read data queries only are allowed. | ||
- 2 — Read data and change settings queries are allowed. | ||
|
||
After setting `readonly = 1`, a user can't change `readonly` and `allow_ddl` settings in the current session. | ||
|
||
When using the `GET` method in the [HTTP interface](../../interfaces/http_interface.md#http_interface), `readonly = 1` is set automatically. To modify data use the `POST` method. | ||
|
||
<a name="settings_allow_ddl"></a> | ||
|
||
## allow_ddl | ||
|
||
Allows/denies [DDL](https://en.wikipedia.org/wiki/Data_definition_language) queries. | ||
|
||
See [above](#permissions_for_queries) for the division of queries into groups. | ||
|
||
**Possible values** | ||
|
||
- 0 — DDL queries are not allowed. | ||
- 1 — DDL queries are allowed. Default value. | ||
|
||
You can not execute `SET allow_ddl = 1` if `allow_ddl = 0` for current session. | ||
|
||
[Original article](https://clickhouse.yandex/docs/en/operations/settings/permissions_for_queries/) <!--hide--> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../../../en/operations/settings/permissions_for_queries.md |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../../../en/operations/settings/permissions_for_queries.md |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../../../en/operations/settings/permissions_for_queries.md |