Query Two Tables
Posted on 2012-09-01
I have a database that has two tables. One table contains the details of a shop order, ie... T-Shirt Size, T-Shirt Color, Quantities of each.
Each item is stored individually but the entire order has a reference number.
The second Table contains the shipping and postage info for the entire order and is associated by the reference number.
How do I query both tables at the same time to see if both tables have the same reference numbers and if table two does not have the reference number and associated info it will print out the reference number from table one?
So, in a nut shell... query both tables and compare if each have a specific reference number and give me a list of entries in table one that do not have a matching reference number in table 2.