Re: [rt.cpan.org #18258] Error in do() using server-side $ placeholders
"Greg Sabino Mullane" <greg-738XdyZ4GzZWk0Htik3J/[email protected]>
| Newsgroups | gmane.comp.db.postgresql.dbdpg |
|---|---|
| Message-ID | <[email protected]> |
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
> After upgrading to 1.47, the code below (also attached) gives an error:
>
> $dbh->do(q{SET search_path TO ?}, undef, 'public');
>
> ERROR: syntax error at or near "$1" at character 20
>
> Note that there is no $$ placeholders in the code above. Trace shows
> that do() tries to execute PQexecParams with ( SET search_path = $1 )
> which, for some reason, fails.
Apparently PQexecParams doesn't like anything but strict DML in it's calls.
I've made modifications to the code in cvs to fix this, it will be a part
of the soon-to-be-released version 1.48 of DBD::Pg. Thanks for the report.
- --
Greg Sabino Mullane greg-738XdyZ4GzZWk0Htik3J/[email protected]
PGP Key: 0x14964AC8 200604030855
http://biglumber.com/x/web?pk=2529DF6AB8F79407E94445B4BC9B906714964AC8
-----BEGIN PGP SIGNATURE-----
iD8DBQFEMRtEvJuQZxSWSsgRArfKAKD+vgycrBb+Zrv45/0BQ3sNvkd7sACcCpEq
KbOEjmgcmnpHuhc8Wt7QiYw=
=1DB0
-----END PGP SIGNATURE-----