Link to home
Start Free TrialLog in
Avatar of pda4me
pda4me

asked on

MySQL SQL Syntax question multiple table query

I have two tables 'Residential' and 'property_coordinates' that feature both feature a sMLSNumber field and the Residential table has a sSubdivision field.  I am trying to select all data where the sSubdivision equals Pines in table Residential and the sMLSNumber matches in both tables.  What am I doing wrong?  Can someone edit my syntax to work properly?
SELECT * FROM Residential, property_coordinates
	WHERE sSubdivision='Pines'
	AND sMLSNumber=sMLSNumber"

Open in new window

Avatar of pda4me
pda4me

ASKER

I fixed a typo " and am now getting this error FYI, how do I work around:

#1052 - Column 'sMLSNumber' in where clause is ambiguous
ASKER CERTIFIED SOLUTION
Avatar of Nellios
Nellios
Flag of Greece image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of pda4me

ASKER

Is there a performance increase in one versus the other?
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of pda4me

ASKER

Thanks!