What is the difference between locking and multi-versioning?



What is the difference between locking and multi-versioning?..

Answer / Javed Akhter

In SQL Server, locking and multi-versioning are two different strategies for managing concurrency and preventing conflicts when multiple users access the same data simultaneously. Locking is a mechanism that prevents multiple transactions from modifying the same data at the same time by placing locks on the resources being accessed. Multi-versioning allows multiple versions of the same data to exist, each associated with a specific transaction. This way, readers can access data without holding locks and writers can modify data without blocking readers. The main difference is that locking can lead to contention, especially in high concurrency environments, while multi-versioning aims to reduce this contention.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More SQL Server Interview Questions

How do I find sql server instance name?

1 Answers  


What do you mean by stored techniques? How would we use it?

1 Answers  


How do you find value of first column before inserting value into the second column in the same table for checking that second column must have different value than first column.

2 Answers   L&T,


How to list all tables in the database using odbc_tables()?

1 Answers  


How do I start sql server agent automatically?

1 Answers  


What are the five characteristics of good data?

1 Answers  


Tell me about Triggers?

3 Answers   Cap Gemini,


What is an extended stored procedure? Can you instantiate a COM object by using T-SQL?

3 Answers   HCL,


How can you find out how many rows returned in a cursor?

1 Answers  


What is the contrast between sql and pl/sql?

1 Answers  


How to modify the underlying query of an existing view?

1 Answers  


What is rank function?

1 Answers  


Categories