Greetings from Australia,
I have a main table Table1 which I have a binary link with Table2 and Table3. There is no data connection between Table2 & Table3...e.g:
A. Table1 -> [Binary Link] -> Table2
B. Table1 -> [Binary Link] -> Table3
I need an SQL SELECT command that can successfully extract all the data from Table1 with LEFT JOINS from Table2 & Table3 via the binary links. I'm adding the links manually via Studio Pro. I'm using an SQL command similar to this:
SELECT TABLE1.**, TABLE2.Field as T2F, TABLE3.Field as T3F FROM TABLE1 LEFT JOIN TABLE2 LEFT JOIN TABLE3 WHERE TABLE1.Field='SomeData' ORDER BY TABLE1.Field
The above generates a semantic error. However, if I remove the reference to Table3, it works. If I have other left joins that are connected via common fields, that also work. e.g.
LEFT JOIN Table7 ON Table1.CommonField=Table7.CommonField
Currently I can only get the data from the number A binary link as above. I want to be able to get the data from B binary link as above, with more similar links in the future to other tables.
Can someone please advise how to do it? I would prefer not to use ObjectPtr or Foreign Key. This is delaying my app development.
Thanks in advance.
Cheers
Grant