I wonder if someone could help. I have created a VB6 Master/detail form that contains data from 2 sources (tblTable1 & tblTable2), however, there is no field that relates the two tables. The actual link is provided from a 3rd table, tblTable3. So the relationship should be as follows:
tbl1_ID1 to tbl2_ID1
then
tbl2_ID2 to tbl3_ID2
Makes sense(?)
The code I have would work if I could find a way of relating tblTable1 and tblTable2 via tblTable3
Current Code:
Recordset.Open "SHAPE {select * from tblTable1} AS ParentCMD APPEND ({select * from tblTable2} AS ChildCMD RELATE tbl1_ID1 TO tbl2_ID1) AS ChildCMD", db, adOpenStatic, adLockOptimistic
Hope someone can help me with this one
Adam
tbl1_ID1 to tbl2_ID1
then
tbl2_ID2 to tbl3_ID2
Makes sense(?)
The code I have would work if I could find a way of relating tblTable1 and tblTable2 via tblTable3
Current Code:
Recordset.Open "SHAPE {select * from tblTable1} AS ParentCMD APPEND ({select * from tblTable2} AS ChildCMD RELATE tbl1_ID1 TO tbl2_ID1) AS ChildCMD", db, adOpenStatic, adLockOptimistic
Hope someone can help me with this one
Adam