in reply to Formatting question??

in your code, you put it into @row, which is wrong, a ref is a scalar:

my @column_names = @{$_read_sth->{NAME_lc}); local $\ = "\n"; # v---- not a @ while (my $row = $_read_sth->fetchall_arrayref) { print join ",", @$row; # Extremely oversimplified }

returning fetch (or fetchrow_arrayref) into @row will cause a structure like this:

$VAR1 = [ undef ];

which is a true value, causing the endless loop


Enjoy, Have FUN! H.Merijn