Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
sub setup_report { my ($count, $email_count, @reports) = @_; $| = 1; my $surname = my $givenName = my $ticket_id = my $support_id = my +$date = my $email = ''; my $file = "QA_Report_" . strftime('%m-%d-%Y', localtime) . ".txt" +; chdir "../reports/" or die "cannot chdir reports $!\n"; open(OUTF, ">$file") or die $!; select(OUTF); format OUTF_TOP = QA Report @<<<<<<< $date Total Count: @<<<<< Email Count: @<<<<< $count, $email_count Name TicketID SupportID Email ------------------------------------------------------------------ . $date = strftime('%m-%d-%y', localtime); write; format OUTF = @<<<<<<<<<< @<<<<<<< @|||||||||| @<<<<<<<< @<<<<<<<< +<<<<<<<<< $givenName, $surname, $ticket_id, $support_id, $email . foreach my $report (@reports){ $givenName = $$report[0] || ""; $surname = $$report[1] || ""; $ticket_id = $$report[2] || ""; $support_id = $$report[3] || ""; $email = $$report[4] || ""; write;} close OUTF;}
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: creating reports without reoccuring heading
by antirice (Priest) on Aug 04, 2003 at 19:38 UTC | |
|
Re: creating reports without reoccuring heading
by LordWeber (Monk) on Aug 04, 2003 at 19:39 UTC | |
|
Re: creating reports without reoccuring heading
by elbow (Scribe) on Aug 05, 2003 at 07:35 UTC | |
|
Re: creating reports without reoccuring heading
by caliban (Novice) on Aug 05, 2003 at 12:25 UTC |