That is very interesting and great reasoning. Thanks for clarifying
that.
On Jul 24, 6:21 pm, Per Djurner <
per.djur...@gmail.com> wrote:
> The convention is that when you are fetching a single record from the
> database (using findOne, findByKey etc) you will get an object back.When you
> are fetching multiple records you will get a query result set back.
> The "returnAs" argument is a way to override this convention (and it will be
> improved a little more before we release 1.0).
>
> The reasoning behind the convention is that when you are asking the database
> for multiple records it is likely that you intend to display them (rather
> than edit/delete them).
> In this case objects are overkill (and even more so because of the poor
> performance of object creation in ColdFusion).
>
> / Per
>
> On Fri, Jul 24, 2009 at 8:54 PM, Mike Henke <
henkem...@gmail.com> wrote:
>
> > This might have been discussed before. I haven't had any issues yet
> > with findall() or findby() when calling a mode but these functions be
> > standardized and return a structure instead of object.
>
> > I am thinking as conventions guy and newbie to CFWheels. Seems odd
> > since CFWheels is about making our lives easier with conventions and
> > assumptions.
>
> > Just something to think about.
>
> > I read about "returnAs" argument on the findAll . Does this do
> > something like I am suggesting.
>
> >
http://groups.google.com/group/cfwheels/browse_thread/thread/9dc86536...
>
> > Thanks