Missing end comment mark '*/'.

Anybody knows why I am getting the error in Query Analyzer?
Below I pasted executed code:


SET QUOTED_IDENTIFIER ON
SET TRANSACTION ISOLATION LEVEL SERIALIZABLE
SET ARITHABORT ON
SET NUMERIC_ROUNDABORT OFF
SET CONCAT_NULL_YIELDS_NULL ON
SET ANSI_NULLS ON
SET ANSI_PADDING ON
SET ANSI_WARNINGS ON

/*
BEGIN TRANSACTION
ALTER TABLE dbo.table_name
      DROP CONSTRAINT DF_table_name_column_name
GO
COMMIT
*/

quasar_eeAsked:
Who is Participating?
 
Anthony PerkinsCommented:
Or:

SET QUOTED_IDENTIFIER ON
SET TRANSACTION ISOLATION LEVEL SERIALIZABLE
SET ARITHABORT ON
SET NUMERIC_ROUNDABORT OFF
SET CONCAT_NULL_YIELDS_NULL ON
SET ANSI_NULLS ON
SET ANSI_PADDING ON
SET ANSI_WARNINGS ON

/*
BEGIN TRANSACTION
ALTER TABLE dbo.table_name
     DROP CONSTRAINT DF_table_name_column_name
-- GO
COMMIT
*/
0
 
Anthony PerkinsCommented:
Try it this way (lose the GO):

SET QUOTED_IDENTIFIER ON
SET TRANSACTION ISOLATION LEVEL SERIALIZABLE
SET ARITHABORT ON
SET NUMERIC_ROUNDABORT OFF
SET CONCAT_NULL_YIELDS_NULL ON
SET ANSI_NULLS ON
SET ANSI_PADDING ON
SET ANSI_WARNINGS ON

/*
BEGIN TRANSACTION
ALTER TABLE dbo.table_name
     DROP CONSTRAINT DF_table_name_column_name
COMMIT
*/
0
 
Aneesh RetnakaranDatabase AdministratorCommented:
u can't use 'GO' inside /* .. */
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.