Subject: | DBI improvement to slice results |
http://search.cpan.org/~timb/DBI-1.607/DBI.pm#fetchall_arrayref
How to fetch each row as array ref by slice by column name?
It seems impossible.
Is next improvement will be reasonable?
diff:
-To fetch only the fields called "foo" and "bar" of every row as a hash
ref (with keys named "foo" and "BAR"):
- $tbl_ary_ref = $sth->fetchall_arrayref({ foo=>1, BAR=>1 });
+To fetch only the fields called "foo" and "bar" of every row as a hash
ref (with keys named "foo" and "BAR"):
+ $tbl_ary_ref = $sth->fetchall_arrayref({ foo, BAR });
+To fetch only the fields called "foo" and "bar" of every row as a array
ref (with keys named "foo" and "BAR").
Values of hash keys is array index where results will be fed:
+ $tbl_ary_ref = $sth->fetchall_arrayref({ foo => 0, BAR => 1 });