in reply to Report Formatting Help
Now you have a two-level hash of the data. At this point, I would suggest using Text::Table to produce the output. Failing that, it's really just: foreach product, foreach column, "print spaced out columns"my %products; for (@lines) { chomp; next unless my ($rep, $prod, $qty) = $_ =~ /(\w+)\s+(\w+)\s+(\d+)/; $product{$prod}{$rep} += $qty; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Report Formatting Help
by Anonymous Monk on Jul 14, 2004 at 03:10 UTC |