Hi all,
I'm hoping someone out there can help as I have been reading all morning so now I need some advice. I have a table where I have defined the primary key as a combination of 2 fields in one table -- the year and a container number(contno). The table holds 4 years of data. A container number can only be used once in a year. So, the year and the contno can be dupes separately but must be unique together. I use a form to add new records and update the table and both of these fields are on the form. As of now, I am allowing these 2 fields to be changed. It seems to work as I am getting Access's error message when the two fields together are not unique. Is allowing the user to change these fields's acceptable? Or is there a better way to do this? I've read a lot about the option of the AutoNumber but that seems to have it's own problems. Thanks for any help!
I'm hoping someone out there can help as I have been reading all morning so now I need some advice. I have a table where I have defined the primary key as a combination of 2 fields in one table -- the year and a container number(contno). The table holds 4 years of data. A container number can only be used once in a year. So, the year and the contno can be dupes separately but must be unique together. I use a form to add new records and update the table and both of these fields are on the form. As of now, I am allowing these 2 fields to be changed. It seems to work as I am getting Access's error message when the two fields together are not unique. Is allowing the user to change these fields's acceptable? Or is there a better way to do this? I've read a lot about the option of the AutoNumber but that seems to have it's own problems. Thanks for any help!