> There is a table t1(member_id integer primary key, member_name text,
> address text, phone text, email text). I have to reach each member by
> either adress, phone or email. Unfortunately some of address field
> have wrong encoded data. In this case I will use phone or email to
> reach them.
>
> Now I need to upgrade to newer PostgreSQL within 1 day. I know I have
> to fix wrong encoded field but it will take more than 1 day. So I
> would like to import the data first then fix wrong encoded field on
> running database since I can reach members by phone or email even with
> wrong encoded address field...
You could add a bytea field in the migration process which
holds the original data and put some "sloppily corrected" data
inside the real field for the time being. Then, once corrected
set the additional bytea field to NULL. Pretty much the
concept of staging tables for data import.
Karsten
--
GPG key ID E4071346 @ wwwkeys.pgp.net
E167 67FD A291 2BEA 73BD 4537 78B9 A9F9 E407 1346