To combine others' ideas, if you really want only one function call, you could do this and then call getPeoplePlacesCompanies when you want all three returned in an array:
<cfcomponent> <cfset variables.aPeoplePlacesCompanies = arrayNew(1)> <cffunction name="getPeople" returntype="query"> <!--- query one ---> </cffunction> <cffunction name="getPlaces" returntype="query"> <!--- query two---> </cffunction> <cffunction name="getCompanies" returntype="query"> <!--- query three ---> </cffunction> <cffunction name="getPeoplePlacesCompanies" returntype="array"> <cfif NOT arrayLen(variables.aPeoplePlacesCompanies)> <cfset arrayAppend(variables.aPeoplePlacesCompanies,getPeople())> <cfset arrayAppend(variables.aPeoplePlacesCompanies,getPlaces())> <cfset arrayAppend(variables.aPeoplePlacesCompanies,getCompanies())> </cfif> <cfreturn variables.aPeoplePlacesCompanies)/> </cffunction> </cfcomponent> -----Original Message----- From: Joe Rinehart [mailto:[EMAIL PROTECTED] Sent: Tuesday, July 29, 2008 8:21 AM To: CF-Talk Subject: Re: Returning multiple recordsets in a single component Hi Scott, I'd probably go Mark's route and make each a method of the cfc: <cfcomponent> <cffunction name="getPeople" returntype="query"> <!--- query one ---> </cffunction> <cffunction name="getPlaces" returntype="query"> <!--- query two---> </cffunction> <cffunction name="getCompanies" returntype="query"> <!--- query three ---> </cffunction> </cfcomponent> -Joe On Jul 29, 2008, at 8:29 AM, Scott Stewart wrote: > Hey all, > > > > I have three related queries, they're not dependant on each other > however. > > They're quick and dirty select statements. > > > > Is there a way to return three query results in a single CF Component? > > > > Thanks > > > > sas > > > > -- > Scott Stewart > ColdFusion Developer > 4405 Oakshyre Way > Raleigh, NC 27616 > (h) 919.874.6229 (c) 703.220.2835 > > > > > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;203748912;27390454;j Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:309858 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4