View Full Version : stupid question: autonumber, legacy data


ed_the_unlucky
01-29-2008, 07:54 PM
version: access 2000.

OK, i have what may be a fantastically stupid question. i did a search (http://www.access-programmers.co.uk/forums/search.php?searchid=1806902&pp=25&page=2) on this and didn't find anything that seemd to address it.

my issue: autonumber field, sole primary key. i am adapting a legacy (non-access) db into access. it was originally an autonumber field but during import, the data type was set to number and of course, i cannot convert it back now into autonumber.

i already duped the PK field as an autonumber and tried an update query to "correct" the autonumbering PK field as i believe is suggested here (http://www.access-programmers.co.uk/forums/showthread.php?t=138484) but it won't permit me to do this.

b/c it's legacy data, i want to preserve the original values in the autonumber, but am unclear on what next steps might be available to me.

thoughts, anyone?

ed

ed_the_unlucky
01-29-2008, 07:57 PM
alternately, i could just update the original PK value to the new value in the tables depending upon that...

nevermind!

[kicks self a few more times for good measure]

ed

neileg
01-30-2008, 08:02 AM
The way to tackle this is to create a table with an autonumber PK and then append the existing data. Access allows an append to the autonumber and will pickup on the next number after the largest value you have appended.