From: "Southworth, Harry" <[email protected]>
> I think that if I append (rather than overwrite) each report with each
> table, I could restructure the code like you suggest. Thanks for
> pointing that out - it hadn't occurred to me. 
> 
> > my %sth;
> > for (0..$#tables){
> >   $sth{$tables[$_]} = $dbh->prepare(
> >    "SELECT * FROM $theTable WHERE usubjid = ?"
> >   );
> > }
> 
> I already tried something like that, but using an array rather than a
> hash. Is there a reason why an array wouldn't work? 

Nope. Not sure why I used a hash. an array and $sth[$_] would work 
just as well.

If this did not help then most likely the problem is elsewhere.

Jenda
===== [email protected] === http://Jenda.Krynicky.cz =====
When it comes to wine, women and song, wizards are allowed 
to get drunk and croon as much as they like.
        -- Terry Pratchett in Sourcery


-- 
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
http://learn.perl.org/


Reply via email to