Code Comments
Programming Forum and web based access to our favorite programming groups.Hi list, When using DBI module as, my $return_list = $sth->fetchrow_arrayref; Can I copy the reference to some other variable say, e.g. my $CopyOfResult = $return_list; and do another query using the same handle and use $CopyOfResult and $return_list? My question is how does perl will release the memory used to store the results? Thanks, Manish
Post Follow-up to this messageShould have read perldoc DBI ======== Note that the same array reference is returned for each fetch, so don't store the reference and then use it after a later fetch. Also, the elements of the array are also reused for each row, so take care if you want to take a reference to an element. See also "bind_columns". ============= Thanks anyways, :-) -Manish On 04/22/2005 11:27 AM, Manish Sapariya wrote: > Hi list, > When using DBI module as, > > > my $return_list = $sth->fetchrow_arrayref; > > Can I copy the reference to some other variable > > say, e.g. > > my $CopyOfResult = $return_list; > > and do another query using the same handle and > use $CopyOfResult and $return_list? > > My question is how does perl will release the > memory used to store the results? > > Thanks, > Manish
Post Follow-up to this message
Show a Printable Version
Email This Page to Someone!
Receive updates to this thread
Powered by vBulletin
Copyright 2000-2006 Jelsoft Enterprises Limited.