On Wed, Feb 2, 2005, John Hansen <[EMAIL PROTECTED]> said: > Instead of SELECT max(columnname) FROM tablename; use: > > SELECT columnname FROM tablename ORDER BY columnname DESC LIMIT 1;
LIMIT is not in ANSI, so MaxDB (formerly SAPdb) and Oracle would cry. This could be a case where we need a variable that's set in the database shims and used in db.c, but I think that the ANSI syntax is something like: SELECT TOP 1 FROM table... ASC/DESC In which case we've got some trouble. Aaron