Unix Technical Forum

problem with xp_trace_settextfilter (SQL Server 7)

This is a discussion on problem with xp_trace_settextfilter (SQL Server 7) within the SQL Server forums, part of the Microsoft SQL Server category; --> I am trying to run a trace on SQL Server 7 using the Query Analyzer tool (not the profiler). ...


Go Back   Unix Technical Forum > Database Server Software > Microsoft SQL Server > SQL Server

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 02-28-2008, 06:06 PM
db dude
 
Posts: n/a
Default problem with xp_trace_settextfilter (SQL Server 7)

I am trying to run a trace on SQL Server 7 using the Query Analyzer
tool (not the profiler). The commands that I run are the following:

DECLARE @queue_handle int
DECLARE @column_value int
SET @column_value = 1|128|1024|512|8192|4
exec xp_trace_addnewqueue 1000, 5, 95, 90, @column_value,
@queue_handle OUTPUT
exec xp_trace_seteventclassrequired @queue_handle, 12, 1
exec xp_trace_settextfilter @queue_handle, NULL, '--%'\r\n
exec xp_trace_getevents @queue_handle, 1, 1, 100

Basically, the intention is to trace all queries, except those that
are commented out by "--". However the filter declared above filters
not only queries that start with "--" but also anyline that has "--"
in it.

For example, "-- select * from authors" gets filtered out (which is
good) however, the query "select * from authors --query number 1" also
gets filtered out(which is bad).

Is there any other way, to send up my trace filter so that only
queries which have "--" in front will get filtered out.

Is this a bug in SQL Server 7. This problem does not appear in SQL
Server 2000 using similar sp_trace_XXX procedures.

Thanks. Any help is appeciated.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 01:55 PM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com