• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 263
  • Last Modified:

MYSQL compare 2 tables

MySQL 5

I have property listings in one table "res" and map coordinates for property listings in "map" table.

I have a geocoder configured but I only want to geocode property listings that do not already have a record in the map table.

So my question is how would I form a query to check?

Both tables have field "ListID" as PK

Thanks!
0
Bang-O-Matic
Asked:
Bang-O-Matic
1 Solution
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
Something like this should do
Select res.*
From res
Left  join map
 On res.id = map.id
Where map.id is null
0
 
Bang-O-MaticAuthor Commented:
Perfect! thank you!
0

Featured Post

Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now