Microsoft KB Archive/199280

= BUG: DTS Query Builder Problem with Inline Comment =

Article ID: 199280

Article Last Modified on 10/15/2002

-

APPLIES TO


 * Microsoft SQL Server 7.0 Standard Edition

-



This article was previously published under Q199280



BUG #: 45854 (SQLBUG_70)



SYMPTOMS
The SQL Enterprise Manager Data Transformation Services (DTS) Query Builder does not correctly build an SQL statement that begins with the SQL Server inline comment '--'. Every line after the comment is treated as part of the comment. The Query Builder does not recognize that the comment ends on the same line that contained the '--' inline comment marker. For example, if you typed the query

select * from titles where title_id > 'B' -- here's my comment AND price > 11.00

And then you clicked Build Query, you would only see the following:

select * from titles where title_id > 'B'

The inline comment and any subsequent lines are all treated as part of the comment.



WORKAROUND
To work around this problem, use the /* comment */ style of comments with the DTS Query Builder instead of the '--' inline comments.

For example, instead of comments like this:

-- This is a comment

Make your comments look like:

/* This is a comment */



STATUS
Microsoft has confirmed this to be a problem in SQL Server version 7.0.

Additional query words: remark remarks in line

Keywords: kbbug kbpending KB199280

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.