FIX: DBCC CHECKCONSTRAINTS Does Not Handle Names with Special Characters

Article translations Article translations
Article ID: 279338 - View products that this article applies to.
This article was previously published under Q279338
BUG #: 351025 (SHILOH_Bugs)
Expand all | Collapse all


When DBCC CHECKCONSTRAINTS encounters names with special characters, such as spaces, it may return an error message that resembles the following:
Server: Msg 156, Level 15, State 1, Line 15 Incorrect syntax near the keyword 'Order'. Server: Msg 156, Level 15, State 1, Line 19 Incorrect syntax near the keyword 'Order'. DBCC execution completed. If DBCC printed error messages, contact your system administrator.


To resolve this problem, obtain the latest service pack for SQL Server 2000. For additional information, click the following article number to view the article in the Microsoft Knowledge Base:
290211 INF: How to Obtain the Latest SQL Server 2000 Service Pack


Microsoft has confirmed that this is a problem in SQL Server 2000. This problem was first corrected in SQL Server 2000 Service Pack 1.


The example error message from the "Symptoms" section came from running the following query:
use Northwind
The error occurs because there are several tables in the Northwind database whose names begin with "Order" and contain spaces; for example, [Order Details Extended] or [Order Subtotals].


Article ID: 279338 - Last Review: October 17, 2003 - Revision: 3.2
  • Microsoft SQL Server 2000 Standard Edition
kbbug kbfile kbfix kbsqlserv2000sp1fix KB279338

Give Feedback


Contact us for more help

Contact us for more help
Connect with Answer Desk for expert help.
Get more support from