MySQL Forums
Forum List  »  New in 4.1: Subqueries

Bug in 4.17?
Posted by: taggy taggs
Date: April 17, 2005 03:27PM

I'm running MySQL 4.1.7-nt, which should from what I've read support subqueries.. but the below query isn't working at all, and I get a

SELECT venue FROM events WHERE postal_code IN (SELECT postal_code,
(3958*3.1415926*sqrt((LATITUDE-43.867044)*(LATITUDE-43.867044) + cos(LATITUDE/57.29578)*cos(43.867044/57.29578)*(LONGITUDE--79.078614)*(LONGITUDE--79.078614))/180) AS zipdistance
FROM pcode HAVING zipdistance <= 1);

Is this possible using subqueries or joins? Or do I have to create some temporary tables?

Options: ReplyQuote


Subject
Views
Written By
Posted
Bug in 4.17?
4192
April 17, 2005 03:27PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.