Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
Log in  ::  Register  ::  Not logged in
Home       Members    Calendar    Who's On

Add to briefcase ««12

How to find the start time of query in the database Expand / Collapse
Posted Tuesday, July 28, 2009 3:15 AM



Group: General Forum Members
Last Login: Friday, September 4, 2015 1:16 PM
Points: 2,365, Visits: 1,859
Do you mean to say that report sql is being repeatedly executed (maybe from diff connections) and you want to find out when this whole thing started ?

"Keep Trying"
Post #760607
Posted Tuesday, July 28, 2009 9:27 AM



Group: General Forum Members
Last Login: Today @ 2:21 AM
Points: 15,988, Visits: 30,352
I just validated it, you can get the start time for a statement within a batch by querying sys.dm_exec_sessions. I posted a blog entry on it here.

"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood..." Theodore Roosevelt
The Scary DBA
Author of:
SQL Server Query Performance Tuning
SQL Server Execution Plans

Product Evangelist for Red Gate Software
Post #760862
« Prev Topic | Next Topic »

Add to briefcase ««12

Permissions Expand / Collapse