[Catalyst] Order_by
Michael Higgins
mhiggins at banfieldgroup.com
Fri Mar 23 20:21:31 GMT 2007
> -----Original Message-----
> From: Doran L. Barton [mailto:fozz at iodynamics.com]
> Sent: Thursday, March 22, 2007 4:00 PM
> To: The elegant MVC web framework
> Subject: Re: [Catalyst] Order_by
>
> Not long ago, Doran L. Barton proclaimed...
> > This is really a DBIC question... but it's like this:
> >
> > my @books = $c->model('My::AppDB::Book')->search(
> > { num_pages => { '>=', $pages }},
> > { order_by => 'title'});
> >
> > Basically, the order_by is the second argument to the
> search() function.
>
> Woops! I should have been more specific. The order_by
> key-value pair is an
> *option* - one of several - that can be enclosed in a hash of
> options that can be passed as the second parameter to the
> search() method.
>
> Sorry I wasn't as clear the first go around.
>
Thanks for the help, Doran -- I need all the clarity I can acquire.
Cheers,
--
Michael Higgins
More information about the Catalyst
mailing list