May 18, 2011 at 3:13 pm
Hello,
I setup a trace on a sql2k sql server. I'd like to filter it by DB ID and by TextData. Basically I want to track a specific DB, but I found that if a query is run from another DB using the fully qualified name db.owner.table it doesn't show up in my trace if I only filter by DB ID. So to be complete I need to account for the case specified. Is it possible when setting up the trace to specify my filters as "OR" conditions and not "AND" conditions?
Thanks,
Gunner
EDIT: just noticed this is a 2005 forum, but I think the question is okay still.
May 18, 2011 at 4:36 pm
If you specify a DB ID and Text Data then it is going to filter by both criteria.
For the Database ID you could use a combination of Greater Than or Equal To Less Than or Equal To and NOT Equal To.
For better, quicker answers on T-SQL questions, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
May 18, 2011 at 5:02 pm
I was getting strange results with filters, and found it more reliable to export the trace file to a SQL table, then run selects with WHERE
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply