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 |
lesponce
Starting Member
8 Posts |
Posted - 2013-07-12 : 12:53:21
|
How do I get a history of executed T-SQL Commands? I need run an audit for the last 3 months by Login Name. Using SQL, instead of products like Idera.Also, how can I do that if the audit that I'm doing is for a linked server. Using the select openquery command? |
|
James K
Master Smack Fu Yak Hacker
3873 Posts |
Posted - 2013-07-12 : 14:34:55
|
Unless you have trace or CDC or something like that enabled, SQL Server does not keep a history of all the queries run against the server. |
|
|
lesponce
Starting Member
8 Posts |
Posted - 2013-07-12 : 14:58:49
|
Thanks James. |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2013-07-13 : 12:14:25
|
another way is to use profiler traces.------------------------------------------------------------------------------------------------------SQL Server MVPhttp://visakhm.blogspot.com/https://www.facebook.com/VmBlogs |
|
|
James K
Master Smack Fu Yak Hacker
3873 Posts |
Posted - 2013-07-13 : 17:49:05
|
You are very welcome. |
|
|
|
|
|