Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
vpcnk
Starting Member
2 Posts |
Posted - 2012-10-25 : 00:14:59
|
how do you see the query plan for a currently running process?by this i do not mean the 'set showplan on' option by which you can see the query plan for a sql statement which you can run or do not run. i want to see the plan for a process which is currently running.i am not able to see anything to serve this end in the profiler either.appreciate the insights. |
|
chadmat
The Chadinator
1974 Posts |
Posted - 2012-10-25 : 01:45:00
|
SELECT * FROM sys.dm_exec_requests rCROSS APPLY sys.dm_exec_query_plan(PLAN_HANDLE) pWHERE Session_id = <the id you want to look at>-Chad |
|
|
|
|
|