Skip to content

Transactions modes (autocommit)  #42140

@den-crane

Description

@den-crane

I believe to be more ANSI compatible Clickhouse should implement this:

A setting transactions_enabled = false (default)

  • false -- old (current) behaviour, no transactions.
  • true -- transactions supported.

A settings autocommit = true (default) applicable only when transactions_enabled = true

  • true - each command (insert, select ... ) automatically starts a transaction and commits / rollsback automatically (when the command finishes successfully / unsuccessfully or with a timeout).
  • false - each command (insert, select ... ) automatically starts a transaction and to end the transaction need to execute commit.

Basically current begin transaction === set autocommit=false (they are synonyms).

Metadata

Metadata

Assignees

No one assigned

    Labels

    featurest-discussionWhen the implementation aspects are not clear or when the PR is on hold due to questions.

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions