Received: from maia.hub.org (maia-3.hub.org [200.46.204.243]) by mail.postgresql.org (Postfix) with ESMTP id 7B2AFB5DBEE for ; Mon, 24 Oct 2011 22:10:51 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.243]) (amavisd-maia, port 10024) with ESMTP id 85412-06 for ; Tue, 25 Oct 2011 01:10:45 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.8.0-rc2 Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by mail.postgresql.org (Postfix) with ESMTP id 1AE93B5DBE4 for ; Mon, 24 Oct 2011 22:10:44 -0300 (ADT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.2/8.14.2) with ESMTP id p9P1Aigg010445; Mon, 24 Oct 2011 21:10:45 -0400 (EDT) To: Greg Williamson cc: "pgsql-admin@postgresql.org" Subject: Re: postgres 9.0.4, pg_restore and indexes In-reply-to: <1319503267.66489.YahooMailNeo@web46110.mail.sp1.yahoo.com> References: <1319493368.35732.YahooMailNeo@web46108.mail.sp1.yahoo.com> <1319503267.66489.YahooMailNeo@web46110.mail.sp1.yahoo.com> Comments: In-reply-to Greg Williamson message dated "Mon, 24 Oct 2011 17:41:07 -0700" Date: Mon, 24 Oct 2011 21:10:44 -0400 Message-ID: <10444.1319505044@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-2.404 tagged_above=-10 required=5 tests=BAYES_00=-1.9, RP_MATCHES_RCVD=-0.504 X-Spam-Level: X-Archive-Number: 201110/111 X-Sequence-Number: 38563 Greg Williamson writes: > What I am I missing ? Or is pg_restore just not capable of restoring the full definition of a table ? There isn't any provision for doing that automatically; it would be a bit tough to determine exactly what the "full definition" consists of in a way that makes everybody happy. (For instance, how about tables that are targets of foreign key references? Functions that are depended on by check constraints or indexes? And so on.) What you can do is use the --list option to get a list of all the objects in the dump, edit that down to what you want, then use the --use-list option to restore the stuff in your abbreviated list. regards, tom lane