Ed,

You should still have a WHERE clause :

SELECT * FROM ROWS AS R1 LEFT JOIN ROWS AS R2 ON (R1.index=R2.index AND
R2.X<=Right) LEFT JOIN ROWS AS R3 ON (R1.index=R3.index AND R3.X>=Left) LEFT
JOIN ROWS AS R4 ON (R1.index=R4.index AND R4.Y>=Bottom) WHERE R1.Y<=Top

Does this work?


Arnaud


----- Original Message ----- 
From: "Ed McNierney" <[EMAIL PROTECTED]>
To: "Arnaud" <[EMAIL PROTECTED]>; "mysql List"
<[EMAIL PROTECTED]>
Sent: jeudi 20 novembre 2003 18:20
Subject: RE: Cannot find an index that will be used for SELECT


Arnaud -

Thanks very much for a suggestion!  Unfortunately, when I do that (I'm not
much of a JOIN expert <g>) I end up selecting ALL the rows in the table.

- Ed




-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to