From: | Philip Warner <pjw(at)rhyme(dot)com(dot)au> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | Pavel(dot)Janik(at)linux(dot)cz, pgsql-hackers(at)postgreSQL(dot)org |
Subject: | Re: Re: pg_dump and LOs (another proposal) |
Date: | 2000-07-06 05:02:23 |
Message-ID: | 3.0.5.32.20000706150223.01ddc890@mail.rhyme.com.au |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
At 13:06 5/07/00 -0400, Tom Lane wrote:
>
> UPDATE userTable SET oidcolumn = tmptable.newLOoid WHERE
> oidcolumn = tmptable.oldLOoid;
>
It's actually nastier than this since there could be multiple oid columns,
implying, potentially, multiple scans of the table.
I suppose
update userTable set
oidCol1 = Coalesce( (Select newLOoid from oidxref where oldLOoid = oidCol1
), oidCol1 ),
oidCol2 = Coalesce( (Select newLOoid from oidxref where oldLOoid = oidCol2
), oidCol2 ),
...
would work, or at least only update each row once, but it looks slow.
----------------------------------------------------------------
Philip Warner | __---_____
Albatross Consulting Pty. Ltd. |----/ - \
(A.C.N. 008 659 498) | /(@) ______---_
Tel: (+61) 0500 83 82 81 | _________ \
Fax: (+61) 0500 83 82 82 | ___________ |
Http://www.rhyme.com.au | / \|
| --________--
PGP key available upon request, | /
and from pgp5.ai.mit.edu:11371 |/
From | Date | Subject | |
---|---|---|---|
Next Message | Philip Warner | 2000-07-06 05:28:49 | Re: 2nd update on TOAST |
Previous Message | Richard Sand | 2000-07-06 04:41:53 | Re: Lessons learned on how to build 7.0.2 on AIX 4.x |