my $results = $dbh->selectall_arrayref(" SELECT MR_M,MR_R FROM MR2 ORDER BY MR_M LIMIT 10 "); for my $row(@$results){ printf "%s\t%s\n",@$row; }