out of memory
am 28.11.2007 05:57:27 von aniaitIs there any way to solve the 'out of memory exception' of perl on
windows? I got this when i tried to dump a large hash into a file
using Dumper.
Is there any way to solve the 'out of memory exception' of perl on
windows? I got this when i tried to dump a large hash into a file
using Dumper.
On Nov 27, 11:57 pm, aniait
> Is there any way to solve the 'out of memory exception' of perl on
> windows? I got this when i tried to dump a large hash into a file
> using Dumper.
Do you have to use Dumper on the whole hash?
What's wrong with:
foreach my $key (keys %myhash) {
print FH $key,":",$myhash{$key}, "\n";
}
or even:
foreach my $key (keys %myhash) {
print FH "KEY=",$key,"\n", Dumper($myhash{$key}),"\n";
}
On Tue, 27 Nov 2007 20:57:27 -0800 (PST) aniait
a> Is there any way to solve the 'out of memory exception' of perl on
a> windows? I got this when i tried to dump a large hash into a file
a> using Dumper.
Try it with the YAML module, you may have better luck (and the results
are quite readable). In general as smallpond suggested you may just
have to do it key by key.
Ted
Quoth aniait
> Is there any way to solve the 'out of memory exception' of perl on
> windows? I got this when i tried to dump a large hash into a file
> using Dumper.
Increase the size of your swapfile :). Windows machines usually don't
have anywhere near enough swap.
Ben