Schedule to update database on: 04/04/2013 to 04/07/13
Proposed: Change field size from 7 characters to 8 characters
NOTE: THIS IS THE PRIMARY KEY FOR THIS TABLE
Table: tblVitem
Field Name: vitemId
Data Type: Text
Field Size: 7 (xxx-999)
Vendors all have a prefix of 3 Letters.
As I enter the subform, I provide the data needed for a
vendor purchase and the OnUpdate event will go to another
table and grab the next incremental part number for this
vendor. Then it is converted to a string and concatenated
to the vendor id. And thus; we have a new vitemId.
Example: AZN is for Amazon. When I enter the data for
an item that AZN can be a vendor for, the VendorItemID
will be created with AZN-001 upon completion.
This 7 digit text field has worked well up until you hit
999 parts to assign to a vendor.
When I ran into this a year or so ago, to fix the immediate
problem, I created secondary vendors as a work-a-round. :-(
So now I have AZN and AZ2 that are vendor files with the
exact same data, except their assigned vendor code. This
is also done to a couple of vendors in my database.
Now that I have time, I would like to fix these issues.
Example: Vendor AZN = Amazon, and I have 999 different items
that I have or can buy from them in our database. To put in
that 1,000th part; I created a AZ2 Vendor that = Amazon. All
data in required fields are the same for both vendors, only the
creation of a bogus vendor AZ2 was used to gain another 999
part numbers to utilize. Wrong approach, but fixed the
immediate problem back when it was discovered as an issue.
So I am planning on reading all parts associated with AZ2. Convert
part number AZ2-001, to AZN-1000. Read in AZ2-002, and convert
this to AZN-1002, etc... down the line. This will force the
vendor name back to what it really should be, and not the bogus
vendor ID that was used to gain more item selections.
My biggest concern is that with these changes, the fields being
changed are also the Primary Keys for these tables. So changing
Item AZN-001 to AZN-0001 as the primary key, will have an effect
on the other tables (links?) that were using AZN-001 as their
key to get data; if I state it right. Will forms, reports, and
other tables be able to still pull the correct data on that
primary key, even though the primary key has changed it's
value from AZN-001 to AZN-0001; however it does still keep
it's position as the primary key? I am not sure how this
will affect my forms and reports and if this is going to get
too deep to fix.
It makes sense the way I am envisioning it, but, a big task
to make sure each step is taken correctly. If I set it up
as a checklist, maybe I can make it go smoothly. :-)
Thank you for any advice, suggestions, solutions, and notes that
are provided. I have lived with the database this long, I just
think it needs to be updated while I have a little time to prepare
the next phase of the database. And the 999 part limit is one
that needs adjusting for the future.
Tim