http://qs321.pair.com?node_id=272726

cosmicsoup has asked for the wisdom of the Perl Monks concerning the following question:

Hello Monks,

My code is simple enough. Straight out of the perl books. And my problem is basic. I want to see the column names in my output. Is there something that I am missing? This code retrieves the data, but not the column names. Is this possible?
my $sth = $dbh->prepare($sql); $sth->execute() || die $sth->errstr; my @row; while (@row = $sth->fetchrow_array) { print IN join("\t", @row), "\n"; }

Thanks, Louis