Linking Tables error

F

Franko

I am new to access and getting an error message

"No unique index found for the referenced field of the primary table."

when I try to join a new table in relationships. Don't understand the message.

Join to table Join from table
tblRefPhyContact tblRefPhyContactNotes

These are the Primary Keys for each, and the unique index.
RefPhyID RefPhyID
ContactID ContactID
NotesID

I do not understand.
 
J

John Vinson

I am new to access and getting an error message

"No unique index found for the referenced field of the primary table."

when I try to join a new table in relationships. Don't understand the message.

Join to table Join from table
tblRefPhyContact tblRefPhyContactNotes

These are the Primary Keys for each, and the unique index.
RefPhyID RefPhyID
ContactID ContactID
NotesID

I do not understand.

It sounds like you should be joining RefPhyID to RefPhyID, and
ContactID to ContactID. Are you perhaps joining just one of these
fields?

John W. Vinson[MVP]
 
F

Franko

Yes I tried joining both RefPhy and Contacts, but received the same message.
I added a NotesID in the Primary table, i then joined all 3,(RefPhy,
Contacts, & NotesID) and the link was accepted. I cannot attach a smapshot of
the relationship, but a snapshot would show you what i am attempting to
setup.

Thanks for the Help.

Francis
 
J

John Vinson

I am new to access and getting an error message

"No unique index found for the referenced field of the primary table."

when I try to join a new table in relationships. Don't understand the message.

Join to table Join from table
tblRefPhyContact tblRefPhyContactNotes

These are the Primary Keys for each, and the unique index.
RefPhyID RefPhyID
ContactID ContactID
NotesID

I do not understand.

I fear you're still going to have either redundant fields or erroneous
joins. Some specific questions:

What is the Primery Key of each table? Is it one field, or are there
two fields with a key icon in table design view?

In the Join, which field is joined to which? (Just tell me fieldnames,
I don't think a picture is needed).

What real-life entity is represented by each table?

What is the real-life meaning of each field - what Attribute of the
entity does RefPhyID represent, for example?

John W. Vinson[MVP]
 
J

John Vinson

I am trying to join
Table 2 RefPhyID & ContactID to Table 4 RefPhyId & ContactsID.(Enforce
Referential Integrity & Cascade Updated Related Fields(Same as other linkes))
I receive an error - "No Unique index found for the referenced field of the
primary table."

For one thing, I'd remove all the Cascade Updates. They apply only
when the Primary Key value is edited in the "one" side table; and
since you can't edit Autonumbers, that should never occur.

Doublecheck that both RefPhyID and ContactID have the "key" icon by
them in Table2. This *should* work if those two fields are in fact the
joint primary key. You can also check the indexes - open Table2 in
design view and click the indexes icon (lightning bolt hitting a
datasheet); is there in fact a unique index (probably named Primary
Key, though any name should work) on those two fields?

John W. Vinson[MVP]
 
A

aaron.kempf

linked tables are obsolete.

use Access Data Projects and keep all your data in one place.

Spit on anyone that uses MDB for ANYTHING

-Aaron
 
F

Franko

Everything is as you suggested. i started a new database, with the same
fields, and it works. I must have something embedded in the old database,
cause the new one works as you suggested.

Thanks for the help.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top