Yes ... I jumped in late without paying attention Michael. I'm tracking now :)
Mark A. Kruger, MCSE, CFG (402) 408-3733 ext 105 www.cfwebtools.com www.coldfusionmuse.com www.necfug.com -----Original Message----- From: Michael Dinowitz [mailto:mdino...@houseoffusion.com] Sent: Tuesday, March 09, 2010 9:35 PM To: cf-talk Subject: Re: query passed by value from a udf? It's not a question of circumvention, just of understanding how things operate under the covers. If a statement is made in the docs that "any variables local to a UDF are destroyed when the UDF is exited", where does it leave things like the query in my example. Either it is not destroyed, and a reference to the query is passed or it is destroyed and a copy (ala the duplicate() function) is passed. Dave holds by the former. Unless I hear from someone who's gone deeper into ColdFusion's internal memory management, I'm going to assume Dave is basically right. How about Railo? Gert, want to chime in? Thanks -- Michael Dinowitz On Tue, Mar 9, 2010 at 10:25 PM, Mark A. Kruger <mkru...@cfwebtools.com> wrote: > > You can circumvent this using duplicate( ) > > <cfset test = duplicate(test())/> > > Which makes a deep copy of the object by value. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Want to reach the ColdFusion community with something they want? Let them know on the House of Fusion mailing lists Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:331517 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm