Without completely understanding the rest of your code, I would bet the rent money that this code will be difficult to (a) get working and (b) maintain.use vars @EXPORT=qw/ &call_vars &commify &dberror $CGI $spec_vars $titlebar $rpt_no $rpt_lbl $rpt_asofdt $rpt_name $project $proj_re +f $attr_dept $attr_descr $attr_award $attr_prog $attr_projpd $attr_f +yr $attr_budgpd $attr_fund $attr_rate $attr_sub $attr_status $attr_sp +ec $attr_equip $attr_resp $attr_pi $rpt_type $from_act_tbl $from_bud_ +tbl $per_crmo $per_fytd $per_fytdadj $per_fytdbal $per_fytdbaladj $att +r_pfyr $ledger $timespan $bud_led_amt $act_led_amt $pre_led_amt $enc_led_ +amt $cell_col $cell_row $acct_sql $src_or_scen $curr_or_stat $src_lbl +$summ_col $summ_row $per_col $per_row $jrnl_col $jrnl_row $ouc_code $proj_di +splay $cell_descr $summ_descr $mycheck $rpt_id $rpt_dates $sql_asofyr $s +ql_asofmo $sql_asofdy $amt_type $led_tbl /;
Why do you have so many variables, especially imported from what appears to be data? Are you actually using all the variables as control or summation in the rest of your program logic? If so, you should probably be modularizing your code instead of passing them back to the caller of this module as a big messy blob.
More than likely, what you should be doing instead is exporting a single subroutine that returns a hash ref containing these values, and focussing the logic on treating these values as a bundle, not broken out into 87-gazillion named Perl variables.
-- Randal L. Schwartz, Perl hacker
Be sure to read my standard disclaimer if this is a reply.
In reply to •Re: Sub call isn't returning values
by merlyn
in thread Sub call isn't returning values
by Lori713
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |