although you might think you do, you really dont need (or want) to have a primary key structured in the way you mentioned
have an auotnumber key, which can then be used to link records in other tables - now if you THEN want additional data in the record, such as the date it was created, or a reference number, then add these in as separate fields. (note if it is unique, the reference number could be used as the primary key - but then you will probably get hung up on making a sequence intact, and stuff like that) - the reference number, and date can always be used to sort your data - the primary key is there to link your data tables together
there will be some discussion on here about whether autonumber primary keys are/can be superfluous - all i can say is i tend to use them, and it doesnt hurt.
the thing is not to get to hung about the structure of the primary key - if you are getting concerned, then you are probably talking about attributes of the entity, and not the primary key. - especially if you have repeated segments of the key - in many applications, primary keys would not necessarily be visible to the user, so it doesnt matter what they are!
Thanx for the tip so far,
The "Pri key" that was requested was this,
MMYY-0000
Where
Jan 2009 will reset the 0000 back to 0001 again.
e.g.
2008
0108-0001 to maybe 1208-5460
When it become
0109-0001 again.
The MMYY is there so that the (Autonumber) does not need to be "unique"
Basically the other purpose for such a PK is for easy searching too.
But what I have managed to do is to keep "MMYY" as 1 field and "Serial" number as another field. But I am trying to keep both a 1 field MMYY-0000.
See attached.
From the form, I managed to "lock" / prevent the user from making changes, I know that I can also hide it, but this is for viewing purposes.
The other problem that I am facing now is when I were to try to generate a report from this data.
See the report in the attached.
The Serial Number 0004 becomes 4 and the date became MM/DD/YYYY.
As I managed to set the field for each of the field individually but is there a way to Set the format for these 2 fields?
Thanx in advance.