Skip to content

sql: add non-trivial implementations of FOR UPDATE, FOR NO KEY UPDATE, FOR SHARE, FOR NO KEY SHARE #40205

@jordanlewis

Description

@jordanlewis

#40206 added parsing for the various row-level lock modes, and treats them like no-ops. This is acceptable for CockroachDB, which only supports SERIALIZABLE transactions, because from a client's perspective there's no way to observe whether any particular transaction needed to be restarted because of a conflict on the rows that were declared as FOR UPDATE, or because of some other conflict - the transaction will have to be restarted in either case.

This issue tracks improving this behavior for performance reasons. There's ongoing work in core to support at least some of these semantics.

Metadata

Metadata

Assignees

Labels

A-sql-pgcompatSemantic compatibility with PostgreSQLC-enhancementSolution expected to add code/behavior + preserve backward-compat (pg compat issues are exception)X-anchored-telemetryThe issue number is anchored by telemetry references.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions