PRB: GO as 1st Word on Line Treated as Batch Terminator (141666)
The information in this article applies to:
- Microsoft SQL Server 6.0
- Microsoft SQL Server 6.5
- Microsoft SQL Server 7.0
This article was previously published under Q141666 SYMPTOMS
When you use ISQL/W or Query Analyzer in SQL Enterprise Manager (SEM), if
the word GO appears as the first word on a new line of an SQL script it is
treated as an end-of-batch signal, regardless of whether or not it is
followed by non-space characters on the same line.
NOTE: On SQL Server 7.0 Service Pack 1 and later, this problem does not occur if the word GO is followed by non-space characters on the same line.
WORKAROUND
Have GO as the first word on a line only if you intend it to be the batch
terminator; otherwise, make sure you have one or more non-space characters
before the word GO on the same line. Command-line ISQL, which treats a GO
on a line all by itself as the end-of-batch signal, does not have this
problem. You can change the command terminator with the /c option of ISQL.
Modification Type: | Major | Last Reviewed: | 11/14/2003 |
---|
Keywords: | kbprb KB141666 |
---|
|