Different Datasources and QoQ
I have to read tables from two different datasources, so I us QoQ
My first query :
<cfquery name="qry1" datasource="db1">
select table1.name,
table1.phone,
table1.empID
from table1
</cfquery>
My second query :
<cfquery name="qry2" datasource="db2">
select table2.empID,
table2.address,
table2.city
from table2
</cfquery>
Then I combine the two using QoQ:
<cfquery name="qry" dbtype="query">
select table1.name,
table1.phone,
tabel1.empId,
table2.address,
tablbe2.city
from table1, table2
where table1.empID = table2.empID
</cfquery>
This works and gives me what I want. Now the requirement is to find all info from table1 even if there are no mathches, so I have to use left join but QoQ seems very limited and will not allow left joins.
How do I read tables from two different datasoruces and then get all info from one table regardless if it is not in the other table, if my above method is incorrect ? (I just typed this so there could be typos)
Thanks
