Skip to content

Update permissions-for-queries.md#43224

Merged
DanRoscigno merged 3 commits intomasterfrom
DanRoscigno-patch-2
Nov 14, 2022
Merged

Update permissions-for-queries.md#43224
DanRoscigno merged 3 commits intomasterfrom
DanRoscigno-patch-2

Conversation

@DanRoscigno
Copy link
Copy Markdown
Contributor

closes #43068

Changelog category (leave one):

  • Documentation (changelog entry is not required)

@tavplubix ,should I also say something about DELETE and UPDATE in here? These (I believe) require ALTER, so need allow_ddl=1.

cc: @dbanda

@DanRoscigno DanRoscigno added pr-documentation Documentation PRs for the specific code PR can be tested Allows running workflows for external contributors labels Nov 14, 2022
The following settings regulate user permissions by the type of query:

- [readonly](#settings_readonly) — Restricts permissions for all types of queries except DDL queries.
- [readonly](#settings_readonly) — Restricts permissions for Write and DDL queries, and selectively on Change settings queries.
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should I also say something about DELETE and UPDATE in here?

It's much easier to enumerate queries that are allowed. I would say that it restricts permissions to all types of queries except readonly queries (like SELECT and equivalent queries), and queries that modify only session context (like USE and (for readonly=2) SET and CREATE TEMPORARY TABLE). Queries like EXISTS, DESCRIBE, SHOW PROCESSLIST, etc are equivalent to SELECT, because they just do select from system tables. EXPLAIN is also equivalent to SELECT.

@tavplubix tavplubix self-assigned this Nov 14, 2022
@DanRoscigno
Copy link
Copy Markdown
Contributor Author

I combined sections and (I think!) simplified.

@DanRoscigno DanRoscigno merged commit 00fe401 into master Nov 14, 2022
@DanRoscigno DanRoscigno deleted the DanRoscigno-patch-2 branch November 14, 2022 19:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

can be tested Allows running workflows for external contributors pr-documentation Documentation PRs for the specific code PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Readonly not working as documented

2 participants