Re: MySQL says, Ich don't think so (Subquery woes)

2006-02-05 Thread Daniel Kasak
René Fournier wrote: Thanks! I will try this Monday. On a related note, does the 'temporary table' approach (creating, locking, dropping) significantly slow down queries? I haven't had to use them yet, and my application is somewhat performance sensitive, so... just curious. It's actually a

MySQL says, Ich don't think so (Subquery woes)

2006-02-04 Thread René Fournier
SELECT MAX(id) FROM history WHERE account_id = 216 GROUP BY asset_id ...works. Returns, e.g.: 1234, 3456, 5483, 8382. SELECT history.* FROM history WHERE history.id IN (1234, 3456, 5483, 8382 ) ...works too. But if I try to combine them using a subquery, a la... SELECT history.* FROM

QL 4.1 or greater.Re: MySQL says, Ich don't think so (Subquery woes)

2006-02-04 Thread Rhino
database. -- Rhino - Original Message - From: René Fournier [EMAIL PROTECTED] To: mysql@lists.mysql.com Sent: Saturday, February 04, 2006 5:38 PM Subject: MySQL says, Ich don't think so (Subquery woes) SELECT MAX(id) FROM history WHERE account_id = 216 GROUP BY asset_id ...works

Re: MySQL says, Ich don't think so (Subquery woes)

2006-02-04 Thread Michael Stassen
René Fournier wrote: SELECT MAX(id) FROM history WHERE account_id = 216 GROUP BY asset_id ...works. Returns, e.g.: 1234, 3456, 5483, 8382. SELECT history.* FROM history WHERE history.id IN (1234, 3456, 5483, 8382 ) ...works too. But if I try to combine them using a subquery, a la... SELECT

Re: MySQL says, Ich don't think so (Subquery woes)

2006-02-04 Thread René Fournier
On 4-Feb-06, at 5:36 PM, Michael Stassen wrote: René Fournier wrote: SELECT MAX(id) FROM history WHERE account_id = 216 GROUP BY asset_id ...works. Returns, e.g.: 1234, 3456, 5483, 8382. SELECT history.* FROM history WHERE history.id IN (1234, 3456, 5483, 8382 ) ...works too. But if I try to