in reply to Program slows dramatically!

For showing up bottleneck in your programm try to use a Benchmark::Timer:
use Benchmark::Timer; $t = Benchmark::Timer->new(skip => 1); foreach my $field (sort @$field_order) { $t->start('tag'); print "\t<TR>\n"; print "\t\t<TH ALIGN=RIGHT>$field :</TH>\n"; for my $i (0 .. $num_recs) { print "\t\t<TD ALIGN=LEFT>$records->[$i]->{$field}</TD>\n" +; } print "\t</TR>\n"; $t->stop; } $t->report;
and Devel::Profiler:
$ perl -MDevel::Profiler your_script.pl
tnan see results
$ dprofpp
If you run your script under mod_perl you can use Devel::Profiler::Apache:
# in httpd.conf PerlModule Devel::Profiler::Apache; # or in startup.pl use Devel::Profiler::Apache;
Because it's very difficult to find out problem just to see a code,
but using of profiler and benchmark help you very well.
Good luck!
      
--------------------------------
SV* sv_bless(SV* sv, HV* stash);