Hello,
I noticed ACCESS SQL doesn't have full outer join. So instead the person writing the SQL statement needs to use UNION ALL.
However I noticed this is not the best way as it doesn't always work, and doesn't always give the proper result.
I have an example that I had tried that I like to share.
I have a table of 40k or it can be 400k records.
Query 1 -
I want to find the counts of all the particular item's occurrence in field A.
Query 2-
With the same table, I want to find the counts of all the particular item's occurrence in field B.
In the two field, there may be items that are not the same - appear in one but not the other and we don't know how many are not the same
(if the programmer do Inner join - he/she could only see same occurrence in both).
I want to join Query 1 and Query 2 together by their item identity (field A & field B) but I want to do full outer join because I want to see all items
even the ones that is in one but not the other. It needs a GROUP BY in each query because it needs the count of items in query A and counts of items in query B
I tried Union but it doesn't work. It just puts them from top to bottom (all results) but you don't know
what item below to what field, it doesn't put them side by side for the two fields of all the items that are there and their count.
- if someone has an SQL statement that works or does it ?
Please advise