Monday, March 12, 2012

How to Capture variables values in a Profiler trace

I have the variables that I pass to the SP, but there are several queries
within the SP that get other variables from the tables being used by it.
Is there a way to create a SQL 2000 trace that will capture the variables
being used within the stored procedure?
Thanks.
No. You might want to write those variables into a table for debugging
purposes. Or simply print them out using PRINT command, while debugging.
Vyas, MVP (SQL Server)
http://vyaskn.tripod.com/
"Mike" <Mike@.Comcast.net> wrote in message
news:OpVXZM5YEHA.1448@.TK2MSFTNGP12.phx.gbl...
> I have the variables that I pass to the SP, but there are several queries
> within the SP that get other variables from the tables being used by it.
> Is there a way to create a SQL 2000 trace that will capture the variables
> being used within the stored procedure?
> Thanks.
>
|||Don't think so. Have you looked into the SQL Debugger?
----
Need SQL Server Examples check out my website at
http://www.geocities.com/sqlserverexamples
"Mike" <Mike@.Comcast.net> wrote in message
news:OpVXZM5YEHA.1448@.TK2MSFTNGP12.phx.gbl...
> I have the variables that I pass to the SP, but there are several queries
> within the SP that get other variables from the tables being used by it.
> Is there a way to create a SQL 2000 trace that will capture the variables
> being used within the stored procedure?
> Thanks.
>
|||I have used the debugger to see them, but I was hoping that I would be able
to capture them to make the tuning a lot easier.
"Gregory A. Larsen" <greg.larsen@.netzero.com> wrote in message
news:er9hLl5YEHA.996@.TK2MSFTNGP12.phx.gbl...
> Don't think so. Have you looked into the SQL Debugger?
> --
> ----
--
> ----
--[vbcol=seagreen]
> --
> Need SQL Server Examples check out my website at
> http://www.geocities.com/sqlserverexamples
> "Mike" <Mike@.Comcast.net> wrote in message
> news:OpVXZM5YEHA.1448@.TK2MSFTNGP12.phx.gbl...
queries[vbcol=seagreen]
variables
>

No comments:

Post a Comment