If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Junction Tables
The examples for handeling many to many relationships (Access 2007) show the
creation of a junction table that includes 2 primary keys in one table, how is this done? -- Andrew H.W. Lochner |
#2
|
|||
|
|||
Junction Tables
On Sat, 20 Dec 2008 07:15:01 -0800, Andrew wrote:
The examples for handeling many to many relationships (Access 2007) show the creation of a junction table that includes 2 primary keys in one table, how is this done? No it contains ONE primary key consisting of multiple fields. Some of those fields are foreign keys to one of the other tables and the others are foreign keys to the remaining one. Example... Table1: PK=ID_1 Table2: PK=ID_2 Junction Table Table3: PK= ID_1, ID_2 -- Rick Brandt, Microsoft Access MVP Email (as appropriate) to... RBrandt at Hunter dot com |
#3
|
|||
|
|||
Junction Tables
On Sat, 20 Dec 2008 07:15:01 -0800, Andrew
wrote: The examples for handeling many to many relationships (Access 2007) show the creation of a junction table that includes 2 primary keys in one table, how is this done? It's *one* primary key consisting of two fields. To create such a primary key, open the table in design view. Ctrl-click the two (up to ten, actually) fields so they're both highlighted; then click the Key icon on the toolbar. -- John W. Vinson [MVP] |
Thread Tools | |
Display Modes | |
|
|