in reply to Re: Re: DBI Placeholders
in thread DBI Placeholders

Nah, prepare is fine. The prepare_cache just saves the corresponding $sth. This may be faster depending on the DB, but as the docs note it may be risky.

-ben

Replies are listed 'Best First'.
Re: Re: Re: Re: DBI Placeholders
by voyager (Friar) on Apr 10, 2001 at 05:21 UTC
    To clarify, DBI takes care of saving the $sth. You don't have to worry about it. From the doc:
    Like prepare except that the statement handle returned will be stored +in a hash associated with the $dbh. If another call is made to prepar +e_cached with the same $statement and %attr values, then the correspo +nding cached $sth will be returned without contacting the database se +rver.
    So you go on about your business and let DBI worry the details.