Re: [ADMIN] what's the efficient/safest way to convert database character set ? - Mailing list pgsql-general

From John R Pierce
Subject Re: [ADMIN] what's the efficient/safest way to convert database character set ?
Date
Msg-id 52607F78.5030800@hogranch.com
Whole thread Raw
In response to [ADMIN] what's the efficient/safest way to convert database character set ?  ("Huang, Suya" <Suya.Huang@au.experian.com>)
Responses Re: [ADMIN] what's the efficient/safest way to convert database character set ?
List pgsql-general
On 10/17/2013 3:13 PM, Huang, Suya wrote:
> I’ve got a question of converting database from ascii to UTF-8, what’s
> the best approach to do so if the database size is very large?
> Detailed procedure or experience sharing are much appreciated!


I believe you will need to dump the whole database, and import it into a
new database that uses UTF8 encoding. Ss far as I know, there's no way
to convert encoding in place. As the other gentlemen pointed out, you
also will have to convert/sanitize all text data, as your current
SQL_ASCII fields could easily contain stuff that's not valid UTF8.

for large databases, this is a major undertaking. I find its often
easiest to do a major change like this between the old and a new
database server.

--
john r pierce                                      37N 122W
somewhere on the middle of the left coast



pgsql-general by date:

Previous
From: Steve Atkins
Date:
Subject: Re: [ADMIN] what's the efficient/safest way to convert database character set ?
Next
From: "Huang, Suya"
Date:
Subject: Re: [ADMIN] what's the efficient/safest way to convert database character set ?