SQL Server query performance optimization analysis transactions and locks (5)

Source: Internet
Author: User
Tags sql server query
SQL Server query performance optimization analysis transactions and locks (I) SQL Server query performance optimization analysis transactions and locks (ii) SQL Server query performance optimization analysis transactions and locks (III) SQL Server query performance optimization analysis transactions and locks (4) (4) undetected distributed deadlocks execute code in SQL2005 (2008), that is, SQLSERVE

SQL server query performance optimization analysis transactions and locks (I) SQL server query performance optimization analysis transactions and locks (ii) SQL SERVER query performance optimization analysis transactions and locks (III) SQL server query performance optimization analysis transactions and locks (4) (4) undetected distributed deadlocks run code in SQL2005 (2008), that is, SQL SERVE

SQL SERVER query performance optimization-analysis of transactions and locks (1)

SQL SERVER query performance optimization-analysis of transactions and locks (2)

SQL SERVER query performance optimization-analysis of transactions and locks (III)

SQL SERVER query performance optimization-analysis of transactions and locks (4)

(4) undetected distributed deadlocks

Run the code in SQL 2005 (2008), the SERVER space, that is, SQL SERVER query performance optimization-analyze the "Example 1" in transactions and locks (2), that is, the following code, for the U.S. server and the Hong Kong virtual host, see.

Select spid process, STATUS, Logon account = SUBSTRING (SUSER_SNAME (sid),), user machine name = SUBSTRING (hostname ), locked = convert (char (3), blocked), database name = SUBSTRING (db_name (dbid),), cmd command, waittype as wait type, last_batch last batch processing time, number of uncommitted transactions in open_tran from master. sys. sysprocessesspid in (select blocked from master. sys. sysprocesses) and blocked = 0

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.