in reply to Re^2: Escaping SQL correctly
in thread Escaping SQL correctly

Well, as I mentioned you can connect to one of the Pg system tables if you have access to Pg at all. If you don't, you may actually be able to do something like this (note no DBI or connection):
use DBD::Pg; my $foo = q{foo'bar'baz}; print DBD::Pg::db->quote($foo); # prints 'foo''bar''bas'

Replies are listed 'Best First'.
Re^4: Escaping SQL correctly
by Anonymous Monk on Mar 08, 2006 at 01:56 UTC

    Thanks!

    I'll probably go with this solution, and if I can't get it to work I'll just install another copy of Postgres and use the template1 database and the quote method. I can write a wrapper that does the placeholder-style operation on my own, I think.

    Your help is much appreciated!