In SQL7 when trying to use ALTER TABLE to make a column longer I get bad syn
tax.
ALTER TABLE table ALTER COLUMN column varchar(90)
It says bad syntax near 'COLUMN'
Other ALTER TABLE statements work like ADD
This works in SQL2000 and as I read it should work in SQL7
Any help appreciatedcheck the compatibility level of the database.
exec sp_dbcmptlevel <database name>
If not 7 then run following command.
sp_dbcmptlevel '<databasename>','70'
Vishal Parkar
vgparkar@.yahoo.co.in|||> If not 7 then run following command.
> sp_dbcmptlevel '<databasename>','70'
Well, make sure it's not in 6.5 compatibility for a reason (e.g. to prevent
ALTER COLUMN statements, or maybe better reason(s)). :-)
Aaron Bertrand
SQL Server MVP
http://www.aspfaq.com/|||Thanks, that was the issue. This database was update from 6.5 some time ago.
Thanks again
Showing posts with label lengthen. Show all posts
Showing posts with label lengthen. Show all posts
Subscribe to:
Posts (Atom)