On 05/07/07, Igor Tandetnik <[EMAIL PROTECTED]> wrote:
Add "group by eid"
For SELECT eid, P, subcase FROM temp a1 WHERE NOT EXISTS ( SELECT * FROM temp a2 WHERE a2.eid == a1.eid AND a2.P < a1.P ) ORDER BY eid GROUP BY eid; I get a syntax error, complaining about GROUP. If I switch the ORDER and GROUP lines, I get the desired result - thanks. What is wrong with the first version? Thanks for the help Jeff ----------------------------------------------------------------------------- To unsubscribe, send email to [EMAIL PROTECTED] -----------------------------------------------------------------------------