View Single Post
  #4  
Old January 24th, 2005, 11:50 PM
John Vinson
external usenet poster
 
Posts: n/a
Default

On Mon, 24 Jan 2005 10:01:03 -0800, "wstokarz"
wrote:

I have treid the Junction Table path. I cannot use a primary key in the Item
table and the Layer table. I must be able to have many entries of the same
Work ID In both the Item Table and Layer Table as well as many items and
layers.


On the contrary: YOU MUST have a primary key in EVERY table.

You may be making the incorrect assumption that a primary key must
consist of one field. In Access, a Primary Key can consist of up to
*ten* fields.

If, as suggested, you make the Primary Key of the Layer table consist
of *THREE* fields - the WorkID, the ItemNo, and the LayerNo - then any
one of these can have multiple records with the same value; that is,
you can have many layers for a given WorkID. However, you will not be
able to enter two records with identical values of WorkID, ItemNo, and
LayerNo, which is exactly the effect you want. Multiple items per
WorkID, multiple layers per Item, but only one unique combination of
the three fields.

John W. Vinson[MVP]