|
Bayo, You can always create a custom query in your custom gateway.
Reactor doesn’t support top in his OO queries. João Fernandes From:
[EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of bayo
ojo Is there no way to just restrict the selection from the database to
just a recordset of 5, cos it looks like this will actually select all and then
one picks the 5 top rows? From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Doug Sims In many cases
you could use Just call getByFields(name=value, name2=value2) with name value
pairs for the criteria to get filtered results, however for the last 5 by date
you will need to create a custom query object and modify the order to sort desc
by modifieddate and sort by that field. On 6/27/06, Jeff
Chastain <[EMAIL PROTECTED]>
wrote: I
have a table with contacts in it that has a lastModified field. I am
looking to get the 5 most recently modified contacts from this table. The
gateway object will return all records, but how do you pass criteria to it ...
i.e. sort by lastModified and give me the top 5? Is this something I need
to custom write into the gateway object? Sorry
if this is too obvious. Thanks --
Jeff
-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- Reactor for ColdFusion Mailing List [email protected] Archives at: http://www.mail-archive.com/reactor%40doughughes.net/ -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- |
- [Reactor for CF] Newbie Question ... Get 5 Most Recent? Jeff Chastain
- Re: [Reactor for CF] Newbie Question ... Get 5 Most R... Doug Sims
- RE: [Reactor for CF] Newbie Question ... Get 5 Most R... bayo ojo
- RE: [Reactor for CF] Newbie Question ... Get 5 Mo... Erik-Jan Jaquet
- RE: [Reactor for CF] Newbie Question ... Get 5 Most R... João Fernandes
