pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Andreas <maps.on@gmx.net>
To: silly sad <sad@bankir.ru>
Cc: pgsql-sql@postgresql.org
Subject: Re: [SPAM]-D] How to find broken UTF-8 characters ?
Date: Mon, 26 Apr 2010 14:41:36 +0200
Message-ID: <4BD58A00.7030905@gmx.net> (raw)
In-Reply-To: <4BD5670A.803@bankir.ru>
References: <4BD4DA7B.3000603@gmx.net>
	<4BD5670A.803@bankir.ru>

Am 26.04.2010 12:12, schrieb silly sad:
> On 04/26/10 04:12, Andreas wrote:
>
> looks like a complete offtopic
Not anymore. The bad signs are in the DB now.

I'd need some command that filters somehow for inconvertible 
(Unicode-->local charset) data.
How can I find those Unicode characters that allready sneaked in?

Actually there shouldn't be anything within the tables that NEED to be 
coded in Unicode.

something like
SELECT * FROM tab_1 WHERE  field_x <>  ConvertToLocal(field_x)
might be a good start.


>> How can I get rid of them?
> iconv -c
AFAIK iconv would translate on file system level but I would think that 
messed up a allready messed up Excel workmap even further.
I'd be glad to handle csv, too.

> BUT
> u should not have those characters at all
> if one is occured it most probably an error

Sure, but those files hit me over a chain of people who consider it ok 
to convert data over numerus file formats, cut, edit, save as X, send 
per mail .... then hit me and I am the one to clean up.


> AND
> u should get rid of this error itself -- not of its consequences.
Like quitting the job and grow flowers instead?
I'll consider this.   ;)




view thread (6+ messages)  latest in thread

Message-ID: <4BD58A00.7030905@gmx.net>
Permalink:  ../4BD58A00.7030905@gmx.net/
Also on:    postgresql.org/message-id/4BD58A00.7030905@gmx.net

 · 

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-sql@postgresql.org
  Cc: maps.on@gmx.net, sad@bankir.ru
  Subject: Re: [SPAM]-D] How to find broken UTF-8 characters ?
  In-Reply-To: <4BD58A00.7030905@gmx.net>

* 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