you need a good SQL tutorial
there are several on my
SQL Links page
meanwhile, in a LEFT OUTER JOIN, rows from the left table which have no matching row in the right table are still returned in the results, but the columns from the right table are all null
therefore if all you want is the unmatched rows,
SELECT Badges.BadgeReference
FROM Badges Left Outer Join Visitors
On Badges.BadgeReference = Visitors.VisitorReference
WHERE Visitors.VIsitorReference
is null
