while ($row = $sth->fetchrow_arrayref()) { if (defined ($row->[2])){ $objects{$row->[0]}{$row->[1]} = $row->[2]; }else{ $objects{$row->[0]}{$row->[1]} = $row->[3]; } }
Thanks
-----
Eschew obfuscation, espouse elucidation!
In reply to Re^2: Creating a csv from two database tables
by joec_
in thread Creating a csv from two database tables
by joec_
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |