g118481
asked on
How to query two tables and merge the results?
I have two tables in Access, table A and table B. I want to query both tables, find the like records and unlike records, and then display the results in Excel. If the record exists in both tables, I only want to show the record from table A.
Can someone provide a code example for me to go by?
Can someone provide a code example for me to go by?
Actually you should post in the Accesss area - not MySql - and you need to post more information such as what do the tables look like? What is the filed that they have in common that you want to compare. DO you want to compare just existance of a single field or differences accross records?
ASKER
MySQL and Access forums would not be able to help with how and where to us CFLOOP nor any CF conditional statements for this request.
I want to query table A and table B, find the like records in both and the records that are not alike, but only display the like records for table A and display the records that are not alike. So, if a record exist in table B, but not in table B, then display it. If a record exist in table A and table B, the display the record in table A, but not the record in table B.
Both tables have like named fields. Here are the field names:
id
codenumber
codephase
codetotal
codeactuals
codemonth
codeid
codesubline
icodenumber
codepace
I want to query table A and table B, find the like records in both and the records that are not alike, but only display the like records for table A and display the records that are not alike. So, if a record exist in table B, but not in table B, then display it. If a record exist in table A and table B, the display the record in table A, but not the record in table B.
Both tables have like named fields. Here are the field names:
id
codenumber
codephase
codetotal
codeactuals
codemonth
codeid
codesubline
icodenumber
codepace
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
you should post this question in mssql area they will be able to give you quick reply.
Regards,
---Pinal