Changing the Primary Key Autonumber

A

Annie

Hi
I have a database that I have cleared out all data and I want to use the
same design for my information this year. I have deleted all records but my
autonumber is now showing as 74 for my first record on the form - can I
change this back to 1 fairly easily.

Many thanks
 
S

Stefan Hoffmann

hi Annie,
I have a database that I have cleared out all data and I want to use the
same design for my information this year. I have deleted all records but my
autonumber is now showing as 74 for my first record on the form - can I
change this back to 1 fairly easily.
Run compact and repair. This should reseed the auto-increment.


mfG
--> stefan <--
 
A

a a r o n . k e m p f

if you used a real database-- like SQL Server, then you cuold simply
TRUNCATE tblLOOKUP and it would reset that one table.

if you rely on Jet, then you need to take the database offline to do
something like this (which is a side effect of running a compact and
repair)
 
S

Stefan Hoffmann

a said:
if you used a real database-- like SQL Server, then you cuold simply
TRUNCATE tblLOOKUP and it would reset that one table.
Sorry, boy, a table can only be truncated if no foreign key on it
exists... a lookup table without makes no sense at all.


mfG
--> stefan <--
 
A

aaron.kempf

dude I'm the only certified DBA around here.

what you say is correct-- but that doesn't mean I should be using Jet.

ADP kicks ass.. anyone who isn't using it is just plain stupid
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top