-
Notifications
You must be signed in to change notification settings - Fork 4.1k
Bug caused by delete operations within a transaction #56111
Copy link
Copy link
Closed
Labels
C-bugCode not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior.Code not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior.O-communityOriginated from the communityOriginated from the community
Description
Describe the problem
I start two transactions.
One of the transaction SELECT operations can get the data, but the DELETE row returns DELETE 0
To Reproduce
What did you do? Describe in your own words.
- Set up CockroachDB node

3.The reading and writing data of T2 are inconsistent
Expected behavior
An error should be reported while performing the DELETE operation.
Additional data / screenshots
create table t(a int primary key); insert into t values(1),(2),(3);
T1:BEGIN;select * from t where a=1;delete from t where a=1;
T2:BEGIN;select * from t where a=1;delete from t where a=1;select * from t where a=1;
Environment:
- CockroachDB version 20.2
- Server OS: Linux
- Client app cockroach sql
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
C-bugCode not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior.Code not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior.O-communityOriginated from the communityOriginated from the community