Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ALTER TABLE (adding AutoMunber field) 1

Status
Not open for further replies.

PrgrmsAll

Programmer
Apr 8, 2003
180
0
0
US
I am trying to do alter a table (using a RunSQL statement within a VBA Module). All I want to do is to add a column at the beginning of the table named 'ID' and set its datatype to be AutoNumber. My statement is as follows:

ALTER TABLE tblANCILLARY ADD COLUMN [ID] AUTONUMBER

It appears MSAccess is having a problem with the datatype designation. I am not supplying the length param since I believe this is only necessary for Text and Int datatypes.

Thanks in advance.
 
ALTER TABLE tblANCILLIARY ADD COLUMN [ID] Counter

John
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top