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 2000 Forums
 Transact-SQL (2000)
 Access Upsizing...

Author  Topic 

alexjamesbrown
Starting Member

48 Posts

Posted - 2007-09-13 : 07:06:23
Hi there,
i have upsized an access database to sql 2000...
most of the tables "Autonumber" fields have correctly been created as identity columns, however there are about 100 that havent.

is there any T-SQL i can run to change each column(0) to Identity?

ValterBorges
Master Smack Fu Yak Hacker

1429 Posts

Posted - 2007-09-13 : 07:20:18
yes. select * from information_schema.columns should have a column which indicates cardinality.

Alter table syntax
http://msdn2.microsoft.com/en-us/library/ms190273.aspx

http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=88112&SearchTerms=while

How to do a sql loop.
http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=89239

PS: If anyone is interested in a SQL Server Job in Connecticut with excellent pay please send me a resume to ValterBorges@msn.com
Go to Top of Page
   

- Advertisement -