Classify concurrency anomaly between two transactions
BitkernelSoftware Engineer · Online AssessmentLast updated
This question evaluates proficiency in database concurrency control and transaction isolation within the Software Engineering Fundamentals domain, focusing on identifying concurrency anomalies that affect data integrity and update correctness.
Two transactions T1 and T2 run concurrently and access the same data item A. Their operations (in order of time) are:
T1readsA = 100.T2readsA = 100.T1writesA = A + 10(so conceptually writes110).T2writesA = A - 10(using its previously read value100, so writes90).
Which description best characterizes the concurrency problem here?
Options:
- A. This operation cannot be repeatably read (non-repeatable read).
- B. This operation has no problems.
- C. This operation reads dirty data.
- D. This operation loses modifications (lost update).
Solution walkthrough is for members
Get the full walkthrough with reference code and complexity analysis, plus Kitty Coach at 300 messages a day. Hints, the code runner and community answers stay free.