Re: How to persist and query a hash lookup in memory with Perl ?



Jack wrote:
once you create the tied hash like the below, and the program is done executing, how do I access the hash and query it from another Perl execution program ??

Like this, for instance:

use DB_File;
tie my %h, 'DB_File', 'fruit', O_RDONLY or die $!;
print "$_: $h{$_}\n" for keys %h;

--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
.