Re: postgres 9.2 error whit apostrophes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Alejandro Brust wrote
>>
>> Two ways to insert that.
>>
>> 1: escape it:
>> update tu02t00 set tu02pfusua = 'D''AGOSTINO' ...
>>
>> 2: Use $$ quotes:
>>
>> update tu02t00 set tu02pfusua = $$D'AGOSTINO$$ ...
>>
> YES, from psql that work great
> I will explain more,
> we were using a jdbc7 from genexus(developers IDE), with PG9.0 and it
> works
> now we upgrade to pg9.2 without migrate the jdbc7 from genexus because
> it seem donsnt work on genexus(developers problem, i know), but
> this is the actual scenario
> so, is any clue?
> Server encoding?
> client encoding?

You should provide the actual string query you are supplying to JDBC as well
as the server's log message containing the entirety of the failing query.

In short, if the JDBC is sending a malformed query to PostgreSQL there is
not likely anything you can do to make PostgreSQL accept it.

The main change along these lines between 9.0 and 9.2 is the setting of the
GUC "standard_conforming_strings" to on by default (this happened in 9.1). 
You might try changing this to "off" and see what happens.

see:
http://www.postgresql.org/docs/9.1/interactive/release-9-1.html
Section E.10.2.1 
for details.

Again, it is impossible to really provide help without knowing exactly what
is being sent to, and more importantly received by, the PostgreSQL server. 
The error message you provided is insufficient.

David J.





--
View this message in context: http://postgresql.1045698.n5.nabble.com/postgres-9-2-error-whit-apostrophes-tp5758840p5758862.html
Sent from the PostgreSQL - admin mailing list archive at Nabble.com.


-- 
Sent via pgsql-admin mailing list (pgsql-admin@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin




[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux