Auto Number

G

Guest

I have a table with a NUMBER field as long integer.It has existing data. I
need to change it to AutoNumber , Starting with 1001. Is this possible? MS
Help tells me that I need to create another field with autonumber, BUT the
number begins with 1 .
 
G

Guest

Hi mn,

If you create a new module and use an SQL code line;

doCmd.RunSQL "INSERT INTO myTable (TableID) VALUES ('1001')"

it will allow you to enter the value of your choice, and from then on will
increment by 1 as you request.

hope this helps,

TonyT..
 
J

Jeff Boyce

Something to consider...

Access Autonumbers are unique row identifiers. That's it. They are not
guaranteed to be sequential (i.e., there will be "gaps" in the sequence).

Autonumbers are unfit for human consumption. If you are trying to do
something with the value (you must be, or why care what value they start
with!), you are misusing Autonumbers, and they will come back to bite you!

You've described "how" you are trying to solve a problem, but have not
describe the problem.

If you offer a more-specific description, the newsgroup readers will be able
to offer more specific suggestions.

Regards

Jeff Boyce
Microsoft Office/Access MVP
 

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

Similar Threads

Access 2010 query for 3 tables 0
autonumber queestion 3
Automatic number combination 2
Auto number 3
Auto fill records 3
Autonumber 7
Autonumber 1
Data Entry Form and Auto Number ID 2

Top