pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: John R Pierce <pierce@hogranch.com>
To: pgsql-jdbc@postgresql.org
Subject: Re: Fwd: Re: Re: Postgresql 9.4.4 - ERROR: invalid byte sequence for encoding "UTF8": 0x92
Date: Sat, 8 Aug 2015 15:00:16 -0700
Message-ID: <55C67BF0.5000308@hogranch.com> (raw)
In-Reply-To: <55C67764.1010601@nqadmin.com>
References: <55C67705.209@nqadmin.com>
	<55C67764.1010601@nqadmin.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-jdbc>

On 8/8/2015 2:40 PM, Prasanth Reddy wrote:
> 1. Is the content vetting new in 9.4?

no, PostgreSQL has always been strict about content types.

> 2. Is there an option to ask the driver not to vet the content? Some times when the users copy notes from a word document there will be some characters invalid in UTF8. Most of these should only be in
> notes columns.

the driver isn't doing this, its happening in the postgres 
database.       you should fix invalid input at the source application 
before sending to the database.

> 3. Is there a way to check the content and fix it/remove invalid characters?

define 'invalid character', then fix it.    this SQL_ASCII field that 
contains 0x92, what character code is that supposed to represent ?

> 4. Is there an option to force the driver to not update database with invalid characters?

the database (NOT the driver) does that already.  if you try and insert 
invalid data, you get an error and have to rollback the transaction.


-- 
john r pierce, recycling bits in santa cruz



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



view thread (16+ messages)  latest in thread

Message-ID: <55C67BF0.5000308@hogranch.com>
Permalink:  ../55C67BF0.5000308@hogranch.com/
Also on:    postgresql.org/message-id/55C67BF0.5000308@hogranch.com

 · 

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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-jdbc@postgresql.org
  Cc: pierce@hogranch.com
  Subject: Re: Fwd: Re: Re: Postgresql 9.4.4 - ERROR: invalid byte sequence for encoding "UTF8": 0x92
  In-Reply-To: <55C67BF0.5000308@hogranch.com>
  References: <55C67705.209@nqadmin.com> <55C67764.1010601@nqadmin.com> <55C67BF0.5000308@hogranch.com>

* 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