Monday, March 26, 2012

History of all SQL Executed

Is there a way to know in SQLSERVER - the history of all the SQL that has
been executed since the last re-start of the Server.
If Profiler is the only way of doing it - what are the performance impact of
running Profiler ( when Profiler writes to a file ) in a production System
Thanks
> If Profiler is the only way of doing it - what are the performance impact
> of
> running Profiler ( when Profiler writes to a file ) in a production System
Profiler can have a negative performance impact if you have a lot of
qualifying events. I suggest that you instead create server-side SQL Trace
to log to a file. You can use Profiler to generate the SQL Trace script.
Hope this helps.
Dan Guzman
SQL Server MVP
"Sumit Pal" <Sumit Pal@.discussions.microsoft.com> wrote in message
news:4C7A8C06-671D-4DE4-AA2F-23B368191A69@.microsoft.com...
> Is there a way to know in SQLSERVER - the history of all the SQL that has
> been executed since the last re-start of the Server.
> If Profiler is the only way of doing it - what are the performance impact
> of
> running Profiler ( when Profiler writes to a file ) in a production System
> Thanks

No comments:

Post a Comment