Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re: Can a DBI Placeholder accept multiple values?

by runrig (Abbot)
on Feb 08, 2008 at 22:06 UTC ( #667082=note: print w/replies, xml ) Need Help??


in reply to Can a DBI Placeholder accept multiple values?

If you're going to prepare/execute this many times, and you only have (up to) a few values, it might be worthwhile to use the join(",", ("?") x $n) technique, and use prepare_cached. If you might have up to many (100?) values, then forget the placeholders and prepare_cached, and use the quote() method on the values if necessary to create dynamic SQL every time.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://667082]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (4)
As of 2022-05-25 13:25 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Do you prefer to work remotely?



    Results (90 votes). Check out past polls.

    Notices?