Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re^2: No apostrophe Insert into MySQL

by Codon (Friar)
on Oct 31, 2005 at 21:16 UTC ( #504422=note: print w/ replies, xml ) Need Help??


in reply to Re: No apostrophe Insert into MySQL
in thread No apostrophe Insert into MySQL

DBI also supplies a quote() method which will quote a string appropriately for your DB. This may save you from massive code refactoring.
my $quoted = $dbh->quote("Wouldn't you rather use bind parameters?");
TMTOWTDI, although some are certainly better than others.

Ivan Heffner
Sr. Software Engineer, DAS Lead
WhitePages.com, Inc.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others chanting in the Monastery: (1)
As of 2016-07-30 03:56 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    What is your favorite alternate name for a (specific) keyboard key?


















    Results (264 votes). Check out past polls.