Jon.Shoberg.Net

Tag: TSQL

TSQL - What is running and percent complete

by admin on Oct.05, 2009, under Dev Data Tech, Misc Items

Here is a quick little snippet of TSQL; what is running and that percent complete.  This comes from using dm_exec_requests and the percent complete value there.


select T.text,
R.Status,
R.Command,
DatabaseName = db_name(R.database_id),
R.cpu_time,
R.total_elapsed_time,
R.percent_complete
from sys.dm_exec_requests R
cross apply sys.dm_exec_sql_text(R.sql_handle) T

Leave a Comment :, more...

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!