RE: [sqlite] group by to return correlated results

2005-06-22 Thread Cronos
Shouldn't it be: select name, day, distance from ( select name as max_name,max(distance) as max_distance from t group by name ) as foo inner join t on t.distance = foo.max_distance and t.name=foo.max_name and this still returns two rows when someone has run the same

RE: [sqlite] qualified names in WHERE clause

2005-05-26 Thread Cronos
It seems to me that MySQL and PostgreSQL are exhibitting some dubious guessing behaviour as to which column it refers to, or perhaps they are making some requirement of the order by to contain a column that is in the resultset ??? If name were only in test11 then what would MySQL and PostgreSQL do

[sqlite] Re: upgrade from 2 to 3

2005-05-21 Thread Cronos
Nevermind, it seems I have found the cause, I was doing: sqlthread->exec("PRAGMA synchronous = 0;",NULL,NULL); sqlthread->exec("PRAGMA cache_size = 4000;",NULL,NULL); but changing it to this has sorted the problem out: sqlthread->exec("PRAGMA

[sqlite] upgrade from 2 to 3

2005-05-21 Thread Cronos
I've just upgraded my program from using v2.8.16 of sqlite to using v3.2.1 of sqlite. So I've change the wrapper class that I was using to use the new prepare() instead of compile() etc. The problem I have is that my program is now running slower - a lot slower, as in one fiftieth of its previous

RE: [sqlite] Multiple inner join confusion

2004-04-12 Thread Cronos
I am also having difficulty getting to grips with the (awkward) join notation. In 3.0 how about support for Oracle type joins with (+) which seems far simpler to me :) -Original Message- From: D. Richard Hipp [mailto:[EMAIL PROTECTED] Sent: 12 April 2004 13:00 Cc: [EMAIL PROTECTED]