in reply to Re: Re: Looping through MySQL
in thread Looping through MySQL

I suggest you take a look at your local DBI documentation, as well as How to RTFM.

What's the point of using 'prepare' if you're not using placeholders?

____________________________________________________
** The Third rule of perl club is a statement of fact: pod is sexy.

Replies are listed 'Best First'.
Re^4: Looping through MySQL
by Aristotle (Chancellor) on Jul 19, 2002 at 22:19 UTC
    The point of prepare() is so as to be returned a statement handle that you can fetch() from; do() doesn't provide that. Maybe you should have a look at aforementioned documentation yourself. :-)

    Makeshifts last the longest.

      If you have a single record, what would you need a statement handle? Didn't you look at the sample data?

      update: oops. I'm wrong. Nice looking out ichimunki Been using DBIx::DWIW lately, and was thinking something theoretically like $DBH->Hash("select * from blah where foo=bar"); Damn, and I was on such a roll. I wonder why Aristotle didn't call me on that, or even andrew. I'll chalk this up to being blinded screaming at the void (see what gryphon had to say at Re: Re: Re: Looping through MySQL)

      ____________________________________________________
      ** The Third rule of perl club is a statement of fact: pod is sexy.

        okay, maybe it's apparent that I rode the short bus to school, but how else are you going to get records without a statement handle, even if there's only one? I thought do() was only for executable actions, like insert, drop, delete, etc... what did I miss?