pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Alejandro Brust <alejandrob@pasteleros.org.ar>
To: posgres support <pgsql-admin@postgresql.org>
Subject: Re: postgres 9.2 error whit apostrophes
Date: Tue, 11 Jun 2013 19:28:06 -0300
Message-ID: <51B7A476.7090504@pasteleros.org.ar> (raw)
In-Reply-To: <CAOR=d=3PDv-eBU7GCS9y6CWgRGT7_2nzHdAaQLrngFpV==wftQ@mail.gmail.com>
References: <51B78F2B.4060107@pasteleros.org.ar>
	<CAOR=d=3PDv-eBU7GCS9y6CWgRGT7_2nzHdAaQLrngFpV==wftQ@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-admin>


El 11/06/2013 18:42, Scott Marlowe escribió:
> On Tue, Jun 11, 2013 at 2:57 PM, Alejandro Brust
> <alejandrob@pasteleros.org.ar> wrote:
>> Hello, excuse my English first
>>
>> we recently move from pg9.0 to pg 9.2 whit this method:
>>
>> from a new server PG9.2 we did:
>> pg_dump -h server -p 5432 -U user -Fc -i -b base-name > bk.backup
>>
>> after that in the new server
>> createdb -T template0 -E LATIN1 basename
>> pg_restore -h server -p 5432 -U user -d basename bk.backup
>>
>> now we are having problems with updates on tables  whit apostrophes like  >>
>> o'higgins << on any character fields
>> First question:
>>             is there  any configurable parameter for PG9.2 that make
>>             update tu02t00 set tu02pfusua = 'D'AGOSTINO'  work...
>>             the server error said
>>
>> ERROR: syntax error at or near "AGOSTINO" at character 187
>>
>> Second question:
>> If there is no way to configure PG9.2 to accept this Cain of update
>> which is the best method to do a downgrade from 9.2 to 9.0 (we are not using
>> any new function)
> That shouldn't work in any version of postgresql.
>
> 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?

thank in advance!!




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



view thread (5+ messages)  latest in thread

Message-ID: <51B7A476.7090504@pasteleros.org.ar>
Permalink:  ../51B7A476.7090504@pasteleros.org.ar/
Also on:    postgresql.org/message-id/51B7A476.7090504@pasteleros.org.ar

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-admin@postgresql.org
  Cc: alejandrob@pasteleros.org.ar
  Subject: Re: postgres 9.2 error whit apostrophes
  In-Reply-To: <51B7A476.7090504@pasteleros.org.ar>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox