On Mar 14, 2007, at 4:48 PM, Oleg Broytmann wrote: > On Wed, Mar 14, 2007 at 04:36:02PM -0400, Fred C wrote: >> How can you translate something like that into something suitable for >> the parameter orderBy ? >> >> items = Item.select(orderBy=()) >> >> rate / 1+ EXTRACT(HOUR FROM AGE(CURRENT_TIMESTAMP, updated)) > > You can pass a string: > > items = Item.select(orderBy="rate / 1+ EXTRACT(HOUR FROM AGE > (CURRENT_TIMESTAMP, updated))")
I have try that before and I got this error AssertionError: Strings in clauses are expected to be column identifiers. I got: 'rate / (1+ EXTRACT(HOUR FROM AGE (CURRENT_TIMESTAMP, updated)))' > PS. I am sure you mean > > rate / (1+ EXTRACT(HOUR FROM AGE(CURRENT_TIMESTAMP, updated))) Yes you are right. I have just forgot a set of parenthesis writing my email. -fred- > Oleg. > -- > Oleg Broytmann http://phd.pp.ru/ > [EMAIL PROTECTED] > Programmers don't die, they just GOSUB without RETURN. > > ---------------------------------------------------------------------- > --- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to > share your > opinions on IT & business topics through brief surveys-and earn cash > http://www.techsay.com/default.php? > page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > sqlobject-discuss mailing list > sqlobject-discuss@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/sqlobject-discuss ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys-and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ sqlobject-discuss mailing list sqlobject-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/sqlobject-discuss