in reply to Re: Looping over multiple queries
in thread Looping over multiple queries

OK, JavaFan, I think you're suggestion works and I *think* I understand it (mostly). Now, my problem is I'm still to much of a noob at handling hash references to know the syntax for extracting the data out of %orgs.

I could keep plowing through Man Perl and surfing Google ... or you could tell me ;^)

Thanks again for the tip

Replies are listed 'Best First'.
Re^3: Looping over multiple queries
by Mad_Mac (Beadle) on Jan 28, 2010 at 19:45 UTC

    Oops. I spoke too soon. I think I got it:

    while (($k, $v)=each (%orgs)){ while (@k = $v->fetchrow_array()) { print "\t$k[0]\n"; } }

    Unless there's a simpler way?
    Thanks again for the tip :^)

Re^3: Looping over multiple queries
by JavaFan (Canon) on Jan 28, 2010 at 19:57 UTC
    Now, my problem is I'm still to much of a noob at handling hash references
    That's not a problem.

    However, what is a problem is that you fail to realize my code snippet doesn't use a hash reference at all. There's a hash - not a reference to a hash.

    Perhaps you want to read an introduction book about Perl first?

Re^3: Looping over multiple queries
by Anonymous Monk on Jan 28, 2010 at 19:41 UTC
    Read through perlintro before you try doing anything else , really :)

      Hmmm... Yep, read that a while back. Which is not the same as saying I completely understood all of the important bits. Besides, I'm more of a trial & error, build it first, understand it later, kind of a guy.

      Irritating? Maybe. Inefficient? Probably. But it's the way I'm wired, and I'm way too old to change now.

      Thanks for the tip, tho' :-)