Solved

comment code in Profiler Trace in TextData Column

Posted on 2009-07-16
4
165 Views
Last Modified: 2012-05-07
After Running profiler, all the text in TextData column seem to start with '--' prefix, which is the comment notation in t-SQL. For example, the following is one TextData element.

-- proc_SelectBenefitsForUser  SELECT  DISTINCT   --r.UserPK,   --r.Progress,   --k.TurnkeyPK,   vw_PayCode, s.[Place] --, z.Tag, b.Tag  FROM   dbo.tblBenefits

Some TextData's start with exec proc_name, without the '--'.

Is this ok? what exactly does it mean? Is there any significance to the '--'

Thanks
0
Comment
Question by:anushahanna
  • 2
  • 2
4 Comments
 
LVL 60

Accepted Solution

by:
chapmandew earned 500 total points
ID: 24872362
I wouldn't pay a lot of attention to the --.  Include the objectname column in the trace so you can see the name easier...use the code in the object to view it...not the textdata in profier.
0
 
LVL 6

Author Comment

by:anushahanna
ID: 24874271
I have the objectname option chosen, but I do not see the Objectname, but objectid in the destination table where I am storing the trace. How does the objectname get converted to objectid?
0
 
LVL 60

Expert Comment

by:chapmandew
ID: 24874770
It depends on the event whether or not the obj name shows...make sure it's checked when you define the trace.
0
 
LVL 6

Author Comment

by:anushahanna
ID: 24877191
yes, it is checked, but it shows as objectid. is there a system table where this objectid has to be converted to objectname?
0

Featured Post

Backup Your Microsoft Windows Server®

Backup all your Microsoft Windows Server – on-premises, in remote locations, in private and hybrid clouds. Your entire Windows Server will be backed up in one easy step with patented, block-level disk imaging. We achieve RTOs (recovery time objectives) as low as 15 seconds.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article explains how to reset the password of the sa account on a Microsoft SQL Server.  The steps in this article work in SQL 2005, 2008, 2008 R2, 2012, 2014 and 2016.
Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
Familiarize people with the process of utilizing SQL Server functions from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Ac…
Viewers will learn how to use the SELECT statement in SQL and will be exposed to the many uses the SELECT statement has.

912 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now