http://www.perlmonks.org?node_id=1078091


in reply to Mysql queries with ' and "

You should be using placeholders, see DBI.