Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 Transact-SQL (2005)
 scripting error: Incorrect syntax near ')'

Author  Topic 

Helloise Smit
Starting Member

22 Posts

Posted - 2008-10-21 : 07:24:42
i have a script creating a whole bunch of tables. i use sqlexpress 2008. it gives the above error on the very last table's create statement..

CREATE TABLE POINTSAWARDINGSYSTEM
(
PASID INTEGER NOT NULL,
MINAMOUNT INTEGER NOT NULL,
POINTSAWARDED FLOAT NOT NULL,
CONSTRAINT PK_POINTSAWARDINGSYSTEM PRIMARY KEY (PASID, MINAMOUNT, POINTSAWARDED)
) //get error here


how do i fix this please
thanks
helloise

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2008-10-21 : 07:29:28
it works for me. i checked
Go to Top of Page

Helloise Smit
Starting Member

22 Posts

Posted - 2008-10-21 : 07:59:21
>
> CREATE TABLE CLOTHINGATTRIBPRICES
> (
> STOCKLOCID INTEGER NOT NULL,
> PLUNUMBER VARCHAR( 14) NOT NULL,
> CLOTHINGGROUPID INTEGER NOT NULL,
> ATTRIBID INTEGER NOT NULL,
> SELLINCL FLOAT,
> LASTCOST FLOAT,
> LISTCOST FLOAT,
> AVERAGECOST FLOAT,
> CONSTRAINT PK_CLOTHINGATTRIBPRICES PRIMARY KEY (STOCKLOCID, PLUNUMBER, ATTRIBID)
> )
>
> CREATE TABLE POINTSAWARDINGSYSTEM
> (
> PASID INTEGER NOT NULL,
> MINAMOUNT INTEGER NOT NULL,
> POINTSAWARDED FLOAT NOT NULL,
> CONSTRAINT PK_POINTSAWARDINGSYSTEM PRIMARY KEY (PASID, MINAMOUNT, POINTSAWARDED)
> )

< ERROR:
Incorrect syntax near ')'


> Script processed in 4 min, 26.469 sec

this is the exact message i have 160 odd tables BEFORE THIS last one...i read this below but it is for sql 2000 i am workin in sqlexpress 2008....

This problem occurs when the SQLDMOScript_Drops option is enabled. When the SQLDMOScript_Drops option is enabled, the generated script includes an additional parenthesis (" ( ").

i dont konw how to fix it though...
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2008-10-21 : 10:23:50
which tool are you using? i was able to run second query also.didnt understand what you mean by SQLDMOScript_Drops option.
Go to Top of Page
   

- Advertisement -