in reply to Printing all values of an AoH

Data::Dumper?

CountZero

"If you have four groups working on a compiler, you'll get a 4-pass compiler." - Conway's Law

Replies are listed 'Best First'.
Re^2: Printing all values of an AoH
by bradcathey (Prior) on Oct 16, 2004 at 20:33 UTC

    Of course, Data::Dumper is great for development, but I was looking for a something to run within the actual script. As in:

    $stmt = qq/SELECT * FROM table WHERE id IN (/ . join(',', ('?') x $categories ) . qq/)/; $sth = $dbh->prepare($stmt); $sth->execute($categories);

    where $categories is a ref to an AoH, and there is only one key name.


    —Brad
    "Don't ever take a fence down until you know the reason it was put up." G. K. Chesterton
      Perhaps have a look into the Data::Dumper source code and see how it gets at the AoH data.

      CountZero

      "If you have four groups working on a compiler, you'll get a 4-pass compiler." - Conway's Law