Hello,



I want to combine three tables in a query. The tables are linked with their keys like this:

A -> B <- C

In other words, one table (B) is linked with its keys to two others. The A:B and C:B relationships are both 1:n. The catch is that the table in the middle, B, will be empty at the beginning. I want users to enter in information that will find entries in A and C and then create a new entry in B based on this information, or retreive it if something already exists. Plus I want the query to be able to be edited.

Is this possible using just SQL, or will I need some scripting too?

I have been able to link two tables with the above criteria, and when data is entered, a new dataset in B is created with the correct link to A. However, I cannot link this with C. Perhaps there is some advanced SQL I'm not aware of?

I have found out that such a query cannot be edited in Access as a query, but can be as a form, if the RecordsetType property of the form is set to Dynaset (Inconsistent Updates). Even so, the problem remains that the first linking works, but the second doesn't.

I understand this is a complicated issue. I can try to explain it more if anyone is interested in helping out. I would appreciate any suggestions!