From: Tom Lane <tgl@sss.pgh.pa.us>
To: Gary Stainburn <gary.stainburn@ringways.co.uk>
Cc: pgsql-admin@postgresql.org
Subject: Re: restored database locale problem
Date: Wed, 28 Dec 2005 11:22:06 -0500
Message-ID: <17656.1135786926@sss.pgh.pa.us> (raw)
In-Reply-To: <200512281607.30488.gary.stainburn@ringways.co.uk>
References: <200512281453.01568.gary.stainburn@ringways.co.uk>
<17461.1135785483@sss.pgh.pa.us>
<200512281607.30488.gary.stainburn@ringways.co.uk>
Gary Stainburn <gary.stainburn@ringways.co.uk> writes:
> goole=# show lc_ctype;
> lc_ctype
> -------------
> en_US.UTF-8
> (1 row)
> goole=# show server_encoding;
> server_encoding
> -----------------
> UNICODE
> (1 row)
Hm. Well, the error message implies that there's some data in the
database that we think is valid but mbstowcs() doesn't agree. If this
is a pre-8.1 release then you could be getting burnt by the bugs we
previously had with more-than-two-byte UTF8 sequences.
> This has arisen from reading back into an existing server config a pg_dump
> that was taken from the same server.
Do you see the error if you just EXPLAIN the problem query, without
executing it? If so, the failure is probably happening because a bogus
data value happens to show up in the pg_stats statistics for one of the
columns used in the query. Since these entries come from a random
sample, re-ANALYZE-ing the table will probably make the EXPLAIN error
come and go. Which leaves you needing to grovel through the whole table
to find the bad data :-(
regards, tom lane
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-admin@postgresql.org
Cc: tgl@sss.pgh.pa.us, gary.stainburn@ringways.co.uk
Subject: Re: restored database locale problem
In-Reply-To: <17656.1135786926@sss.pgh.pa.us>
References: <200512281453.01568.gary.stainburn@ringways.co.uk> <17461.1135785483@sss.pgh.pa.us> <200512281607.30488.gary.stainburn@ringways.co.uk> <17656.1135786926@sss.pgh.pa.us>
* 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