Results 1 to 2 of 2
Thread: To Auto or Not? (XP)
2002-11-17, 19:18 #1
- Join Date
- Jul 2002
- New Hampshire
- Thanked 0 Times in 0 Posts
To Auto or Not? (XP)
I am updating a '97 application to XP. For several reasons, I'm creating a whole new application. For billing and accounting purposes, I need to retain the original Company ID numbers (253 records range in IDs from 1000 to 4256, all 4-digit numbers).
I want my new "Companies" form to have a field, "Account Number." If the company has an existing Company ID, the Account Number should equal that existing Company ID.
Using Helen Feddema's technique, I'm able to insert a new "Auto ID" field in the Companies table that auto-increments new, 4-digit IDs for new companies.
Now, on my "Companies" form, I want the "Account Number" field to reflect the number in the Company ID field (imported from the previous application), when such a number exists. Then, when the Company ID field is blank (empty, null) I want the Account Number field to reflect the new, 4-digit AutoID that my new application auto-increments.
How do I make this happen.
2002-11-18, 02:56 #2
- Join Date
- Jun 2001
- Crystal Beach, FL, Florida, USA
- Thanked 34 Times in 34 Posts
Re: To Auto or Not? (XP)
If you import your old Companies into your new Company table, your old Company # will be in the new Company # autonumber field. Autonumbering will pickup with the next # after your largest existing #.
That being said, I am always a little wary of using autonumber fields when that field is going to be made known to the user. Once a number has been assigned, it can't be changed; and frequently it raises concerns when users find gaps in the numbering.