SELECT FOR UPDATE from a secondary index has no effect #88251
Labels
C-bug
Code not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior.
O-qa
T-kv
KV Team
X-duplicate
Closed as a duplicate of another issue.
Describe the problem
If a SELECT ... FOR UPDATE statement happens to scan a secondary index, it does not block other updates.
To Reproduce
In one SQL session:
In another SQL session:
Expected behavior
The update statement should block until the first SQL session commits or rolls back. The predicate
WHERE c = 1
causes a scan of index c_idx, but if the primary index is scanned, the update blocks.Jira issue: CRDB-19748
The text was updated successfully, but these errors were encountered: