X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id BDAF03A4352 for ; Mon, 1 Nov 2004 02:22:05 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 52246-03 for ; Mon, 1 Nov 2004 02:21:59 +0000 (GMT) Received: from millenium.mst.co.jp (unknown [210.230.185.241]) by svr1.postgresql.org (Postfix) with ESMTP id 6ED5D3A3B04 for ; Mon, 1 Nov 2004 02:21:59 +0000 (GMT) Received: from mst1x5r347kymb (lc12114 [192.168.1.114]) by millenium.mst.co.jp (8.11.6p2/3.7W) with SMTP id iA12LxZ11653; Mon, 1 Nov 2004 11:21:59 +0900 Message-ID: <017501c4bfb9$a70b7f20$7201a8c0@mst1x5r347kymb> From: "Iain" To: Cc: Subject: pg_restore TODO - delay PK creation Date: Mon, 1 Nov 2004 11:22:31 +0900 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_0171_01C4C005.13E9DEC0" X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2900.2180 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180 X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.8 tagged_above=0.0 required=5.0 tests=HTML_30_40, HTML_MESSAGE X-Spam-Level: X-Archive-Number: 200411/3 X-Sequence-Number: 15388 This is a multi-part message in MIME format. ------=_NextPart_000_0171_01C4C005.13E9DEC0 Content-Type: text/plain; charset="iso-2022-jp" Content-Transfer-Encoding: 7bit Hi, I'm wondering if this is already on some todo list for pg_restore but I didn't find any mention of it anywhere, so I thought I should post this and see what people think.. Basically, I'd like to see an option at restore time to not include the primary key constraint when issuing the create table command. I'd like the PK to be added after data has been loaded using an ALTER command. The principle reason for this is performance. There may also be a bug somewhere, or perhaps just a problem with my system, but I was trying to restore a fairly large table (over 7000000 rows) which would run for a couple hours before failing. Dropping the PK enabled the load to complete in 3 or 4 minutes. Adding the PK took another 3 or 4 minutes which adds up to quite a difference. regards Iain ------=_NextPart_000_0171_01C4C005.13E9DEC0 Content-Type: text/html; charset="iso-2022-jp" Content-Transfer-Encoding: quoted-printable
Hi,
 
I'm wondering if this is = already on some=20 todo list for pg_restore but I didn't find any mention of it anywhere, = so I=20 thought I should post this and see what people = think.. 
 
Basically, I'd like to see an = option at=20 restore time to not include the primary key constraint when issuing the = create=20 table command. I'd like the PK to be added after data has been loaded = using an=20 ALTER command.
 
The principle reason for this = is=20 performance.
 
There may also be a bug = somewhere, or=20 perhaps just a problem with my system, but I was trying to restore a = fairly=20 large table (over 7000000 rows) which would run for a couple hours = before=20 failing. Dropping the PK enabled the load to complete in 3 or = 4 minutes.=20 Adding the PK took another 3 or 4 minutes which adds up to quite a=20 difference.
 
regards
Iain
------=_NextPart_000_0171_01C4C005.13E9DEC0--