order_by

[prev] [thread] [next] [Date index for 2004/12/23]

From: jay
Subject: order_by
Date: 10:23 on 23 Dec 2004
Hi

I have a list of news articles in a database which I want to retrieve in date order. I can't find a way to do this. I've tried:

my @news = $self->search({order_by => 'date'});

but I get the following error:

order_by is not a column of Functions::News at news.cgi line 38

which makes sense I guess. I'm sure this must be very easy to do - where am I going wrong?

Cheers
Jay

order_by
jay 10:23 on 23 Dec 2004

Re: order_by
Stray Toaster 10:28 on 23 Dec 2004

Re: order_by
Tony Bowden 10:37 on 23 Dec 2004

Re: order_by
Stray Toaster 10:41 on 23 Dec 2004

Generated at 12:15 on 16 Jan 2005 by mariachi v0.52