Need to create a sequential number...

  • Thread starter Thread starter Olot
  • Start date Start date
O

Olot

I'm importing names for a mailing list to be mailed out
and after I import the file, I'd like to run an (update
query?) that assigns a sequential number to each record.

I've been using autonumber but it is too labor
intensive. My number field needs to be 5 digits and
starts with 10001. (So I have a table created blank with
the autonumber ready to start at 10001 and just import
the names)

Obvoiusly I'm a novice in the programming department, but
I'd still like to create an easier way. I can put the
10001 value in another table that can be used to lookup
the starting point, "MailListID" is the field that links
to the table that has the MailList details.

Any help would be appreciated, using vb code would
require you telling me where to place it and run it...
doh!
 
Hi ,

My name is Dennis Schmidt. Thank you for using the Microsoft Windows
Installer Newsgroups.

The following Microsoft Knowledge Base article is the easiest way to set
the initial value of an autonumber field:

http://support.microsoft.com/default.aspx?scid=kb;en-us;209696


ACC2000: How to Use an Append Query to Set
Initial Value of an AutoNumber Field

I hope this helps! If you have additional questions on this topic, please
reply to this posting.

Need quick answers to questions like these? The Microsoft Knowledge Base
provides a wealth of information that you can use to troubleshoot a problem
or answer a question! It's located at
http://support.microsoft.com/support/c.asp?M=F>.

This posting is provided "AS IS" with no warranties, and confers no rights.
You assume all risk for your use. © 2001 Microsoft Corporation. All rights
reserved.

Regards,
Dennis Schmidt
Microsoft Support
 
Hi, thats the method I'm using now. Problem is, I need to
keep the number as a 5 digit number, and at the same time
not delete the records once I exceed 99999.

Everytime I import a set of records, I'd like to start at
10001 and sequence from there. It's a pain to always
append every record into the copied table and then into
the master file.

Is there a way to run some sort of update query on the
records that are null in the number field and start with
10001 and sequence from there?

thanks in advance...
 
Back
Top