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 Wanet Telecoms Ltd on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Auto Number in Acces forms

Status
Not open for further replies.

gk759

IS-IT--Management
Jun 28, 2001
46
US
Hi,

I would like to know if there is a way to start auto number ID from e.g 5674. Cause the last database had lot numbers that stopped at this number so I have to initiate the new database to begin with 5674. The form i'm making should increment this number everytime the next record is opened. I was told to fill blank records and delete them but there must be a easier way. If someone can help me with this .
I would really appreciate it,

Thanks,

Gary [peace]
 
There is information in the help system under "Autonumber"
but the principle is that you make an append query with the record Id the Primary set to the new number you want to start with.
 

Let’s say you want the numbering to begin with a different number other then 1. Let’s say 5674. Create your table with NO data and no primary key. Have a field called ID and make the data type Number. Save your table. Select your table, right click and select Copy. Then right click and select Paste. Give it a new table name and select Structure Only. Open up this new table and create one record with ID the starting number one less then the one you want, in this case 5673. Close this table. Open the first table and now make the ID field an Autonumber type. Close the table. Create an append query from the second table appending the one record to the first table. Now open the first table and add another record. It will automatically be 5674. Delete record number 5673.

Neil
 
It works!!!

Thanks a lot!

Neil and Trenddsetter.

I really appreciate your suggestions.


-Gary [2thumbsup]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top