On 13/09/05, Brian Kotek <[EMAIL PROTECTED]
> wrote:
Beans are generally meant to wrap up data for a single entity. IE a
single product for a product details page. If you are displaying a
list of 10 product names and prices it is overkill
to create 10 Product objects. In most cases you can just use a query
result set when working with sets like that.
On 9/13/05, Stephen Adams <[EMAIL PROTECTED]> wrote:
> The what would be the point of a Bean? I thought the reason for them was to
> separate between the data and the UI.
>
>
> On 13/09/05, Roland Collins < [EMAIL PROTECTED]> wrote:
> >
> >
> >
> > Why not just use the query on your display page? The query is already an
> encapsulated data object.
> >
> >
> >
> > ________________________________
>
> >
> > From: [EMAIL PROTECTED] [mailto: [EMAIL PROTECTED]] On
> Behalf Of Stephen Adams
> > Sent: Tuesday, September 13, 2005 9:13 AM
> > To: [email protected]
> > Subject: [CFCDev] Multiple results from a query passing into a bean
> >
> >
> >
> >
> > HI,
> >
> > I'm having real trouble working out how to get multiple results from a
> query into a Bean to then pass to my display page. There's two ways I can
> think of doing this, one, create a Bean object for each row returned and
> passing the details of the row to that Bean. So I'd run my query the loop
> through the results and create a bean object at the top of the loop and use
> the Set methods of that bean to store the results.
> > This sounds to me that there is a lot objects being created and this could
> slow everything down.
> >
> > The second way I can see to do this is to run the query then create a Bean
> object, which contains a array of struct's that hold the results of the
> query, then how do I get the results out of this array of structs to display
> in my pages?
> >
> > Are these two options possible or am I missing something fundamental here?
> >
> > Stephen
> >
> ----------------------------------------------------------
> > You are subscribed to cfcdev. To unsubscribe, send an email to
> [email protected] with the words 'unsubscribe cfcdev' as the subject of the
> email.
> >
> > CFCDev is run by CFCZone (www.cfczone.org) and supported by CFXHosting
> (www.cfxhosting.com).
> >
> > CFCDev is supported by New Atlanta, makers of BlueDragon
> > http://www.newatlanta.com/products/bluedragon/index.cfm
> >
> > An archive of the CFCDev list is available at
> www.mail-archive.com/[email protected]
> ----------------------------------------------------------
> > You are subscribed to cfcdev. To unsubscribe, send an email to
> [email protected] with the words 'unsubscribe cfcdev' as the subject of the
> email.
> >
> > CFCDev is run by CFCZone (www.cfczone.org) and supported by CFXHosting (
> www.cfxhosting.com).
> >
> > CFCDev is supported by New Atlanta, makers of BlueDragon
> > http://www.newatlanta.com/products/bluedragon/index.cfm
> >
> > An archive of the CFCDev list is available at
> www.mail-archive.com/[email protected]
>
> ----------------------------------------------------------
> You are subscribed to cfcdev. To unsubscribe, send an email to
> [email protected] with the words 'unsubscribe cfcdev' as the subject of the
> email.
>
> CFCDev is run by CFCZone (www.cfczone.org) and supported by CFXHosting
> (www.cfxhosting.com).
>
> CFCDev is supported by New Atlanta, makers of BlueDragon
> http://www.newatlanta.com/products/bluedragon/index.cfm
>
> An archive of the CFCDev list is available at
> www.mail-archive.com/[email protected]
----------------------------------------------------------
You are subscribed to cfcdev. To unsubscribe, send an email to [email protected] with the words 'unsubscribe cfcdev' as the subject of the email.
CFCDev is run by CFCZone (www.cfczone.org) and supported by CFXHosting (www.cfxhosting.com).
CFCDev is supported by New Atlanta, makers of BlueDragon
http://www.newatlanta.com/products/bluedragon/index.cfm
An archive of the CFCDev list is available at www.mail-archive.com/[email protected]
----------------------------------------------------------
You are subscribed to cfcdev. To unsubscribe, send an email to [email protected] with the words 'unsubscribe cfcdev' as the subject of the email.
CFCDev is run by CFCZone (www.cfczone.org) and supported by CFXHosting (www.cfxhosting.com).
CFCDev is supported by New Atlanta, makers of BlueDragon
http://www.newatlanta.com/products/bluedragon/index.cfm
An archive of the CFCDev list is available at www.mail-archive.com/[email protected]
