I don't think there is a way to get the AutoNumber to start at 25000 -- but you could build a calculated field in a query that adds 25000 to your autonumber.
For instance if your autonumber field was called TestID
Your calculated field could be an expression like:
ID : [TestID] + 25000
Hope this helps
Thanks
Tim
If you are trying to do this to a new table, it's pretty simple. Create your table and before you enter any data into the table, use an insert query to add the first record to the table.
Like so:
INSERT INTO TableName (autonumber) VALUES (25000);
This will create a record with the value you used as the autonumber field. Subsequent records will increment from the number you chose. Mind you, this only will work once on a newly created table.
Thanks Ymesei, I used that route. Tho I am going to have to remember about calculated fields Chesterex1. But Ymesei, I tried it, realized I wanted a different number, and did it again to the same table. So you can use that method over and over. You can even do it on a table with data. It simply makes the next autonumbered record start from your seed.
You ought to read Michael Red's faq700-184 to get further background on autonumber and search this forum for other posts on autonumber (there are many). There are strong feelings about autonumber on all sides of the issue and you should at least be aware of what is being said.
Interesting. I had originally a table with 1 row. This row contained a number. My app would read the number and replace it with an incremented value. Problem was I began getting duplicate order numbers. Yuck. Maybe I should learn how to do a better lock on the table via .Net.
Your right. I realize now that you can change the autonumber to a higher number, but not a lower number. For example if your autonumber is at 12000 and you want to reset to a lower number, you can't just delete all the existing records and lower the autonumber.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.