SQL Server Row version control

Source: Internet
Author: User

When does the line version start?

When we find that there are a lot of read/write blocking in the system, it is time to turn on the line version. Important: Write blocking scenario line version technology can not solve

Open mode:

--set to single user alter DATABASE MyTest set Single_user with ROLLBACK IMMEDIATE; go--Open row version (transaction level) ALTER DATABASE MyTest SET allow_snapshot_isolation on; go--Open Statement-level row version ALTER DATABASE MyTest set READ_COMMITTED_SNAPSHOT on with no_waitgo--set to multi-user ALTER DATABASE MyTest set Multi_u SER with ROLLBACK IMMEDIATE; GO

To turn on statement-level row versioning note points:

if Read_ Committed_snapshot is set to ON, the database engine uses row versioning to provide a transactionally consistent snapshot of the data for each statement, The downside is that the user is reading a data value that is not a dirty data, but is likely to expire immediately after being modified. If data modifications are made based on this expired value, a logic error is generated.

SQL Server Row version control

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.