80 likes | 185 Views
Concurrent Access Problems. On Transaction Processing. Concurrent Access Problems. 3 Problems: Lost Updates Uncommitted Data Inconsistent Retrieval. Lost Updates. Assume Transaction 1 : Update Inventory set PROD_QOH=PROD_QOH+100; Transaction 2 : Update Inventory
E N D
Concurrent Access Problems On Transaction Processing
Concurrent Access Problems • 3 Problems: • Lost Updates • Uncommitted Data • Inconsistent Retrieval
Lost Updates Assume Transaction 1: Update Inventory set PROD_QOH=PROD_QOH+100; Transaction 2: Update Inventory set PROD_QOH=PROD_QOH-30;
Lost Updates • Transaction 1: 3 processes • Read PROD_QOH • PROD_QOH=PROD_QOH+100 • WRITE PROD_QOH
Lost Updates Table 9.2 Table 9.3
Uncommitted Data Assume Transaction 1: Update Inventory set PROD_QOH=PROD_QOH+100; Rollback; Transaction 2: Update Inventory set PROD_QOH=PROD_QOH-30;
Uncommitted Data Table 9.4 Table 9.5
Inconsistent Retrievals Table 9.6 Table 9.7