MSUser (MSUser (AT) discussions (DOT) microsoft.com) writes:
Quote:
when textData is:
exec sp_execute <number> @xx=2222 @yy=3333
Is there a way to find the sql behind the sp_execute? |
If there is an "sp_prepare" with the same number in the thread, there is.
If you include sql_handle in the trace, you look can up the text for the
cache entry. Or? No, you probably only get the call to sp_execute. :-(
I don't remember if you see the individual statements if you include
StmtCompleted, but I have a nagging feeling that you don't.
--
Erland Sommarskog, SQL Server MVP, esquel (AT) sommarskog (DOT) se
Links for SQL Server Books Online:
SQL 2008: http://msdn.microsoft.com/en-us/sqlserver/cc514207.aspx
SQL 2005: http://msdn.microsoft.com/en-us/sqlserver/bb895970.aspx
SQL 2000: http://www.microsoft.com/sql/prodinf...ons/books.mspx