$sth->execute(); my $cols = $sth->{NAME_lc}; my %row; $sth->bind_columns( \@row{@$cols} ); while ( $sth->fetch ) { print "$row{$_} " for @$cols; print "\n"; }