SQL Clone
SQLServerCentral is supported by Redgate
Log in  ::  Register  ::  Not logged in

Get your favorite SSC scripts directly in SSMS with the free SQL Scripts addin. Search for scripts directly from SSMS, and instantly access any saved scripts in your SSC briefcase from the favorites tab.
Download now (direct download link)

SQL Server Long Query Script

By Yusuf Kahveci,

In general, I'm going to give you a script that will give you access to the data that everyone is curious about and wants to learn. What is the longest running query in SQL Server?
Yes, the question that companies usually ask first is this question, which does not end with it. How do we correct after the birth? etc. as.
With the Query below, you can find your long running queries.

Total article views: 1599 | Views in the last 30 days: 1