I scripted a table from my local SQL Server and tried to run it on a dev box and got: Msg 170, Level 15, State 1, Line 11 Line 11: Incorrect syntax near '('. USE [dev] GO /****** Object: Table [dbo].[benefit] Script Date: 06/18/2007 09:34:53 ******/ SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO CREATE TABLE [dbo].[benefit]( [bb_id] [int] IDENTITY(1,1) NOT NULL, [file_id] [nchar](15) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL, [corporate_reviewer] [nchar](3) COLLATE SQL_Latin1_General_CP1_CI_AS NULL, [branch_associate] [nvarchar](50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL, [internal] [bit] NULL, [ppc] [nchar](10) COLLATE SQL_Latin1_General_CP1_CI_AS NULL, CONSTRAINT [PK_borrower_benefit] PRIMARY KEY CLUSTERED ( [bb_id] ASC )WITH (IGNORE_DUP_KEY = OFF) ON [PRIMARY] ) ON [PRIMARY] Code (markup): I can't understand why it wouldn't run on a second instance of SQL server. Any ideas are appreciated.
For any chance, Can local sql be 2005 and dev box can be sql 2000? If I am correct try without using WITH (IGNORE_DUP_KEY = OFF) ON [PRIMARY] And also I found that sql 2000 without sp4 may give errors.
Local is 2005 and I believe dev is 2003. I removed "WITH (IGNORE_DUP_KEY = OFF)" and left "ON [PRIMARY]" in place and it worked. I saw when I scripted a table from dev it didnot have "WITH (IGNORE_DUP_KEY = OFF)". Thanks.