Received: from maia.hub.org (maia-3.hub.org [200.46.204.243]) by mail.postgresql.org (Postfix) with ESMTP id 227C11337BB4 for ; Tue, 19 Apr 2011 22:59:26 -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 97132-03 for ; Wed, 20 Apr 2011 01:59:19 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from elasmtp-scoter.atl.sa.earthlink.net (elasmtp-scoter.atl.sa.earthlink.net [209.86.89.67]) by mail.postgresql.org (Postfix) with ESMTP id 2F9671337BA8 for ; Tue, 19 Apr 2011 22:59:19 -0300 (ADT) Received: from [66.128.249.226] (helo=[192.168.24.108]) by elasmtp-scoter.atl.sa.earthlink.net with esmtpa (Exim 4.67) (envelope-from ) id 1QCMhI-0006jd-Vp; Tue, 19 Apr 2011 21:59:17 -0400 Subject: Re: PKs without indexes From: John P Weatherman Reply-To: jweatherman91@alumni.wfu.edu To: pgsql-admin@postgresql.org Cc: john.weatherman@centerstone.org In-Reply-To: <594449.61680.qm@web39702.mail.mud.yahoo.com> References: <594449.61680.qm@web39702.mail.mud.yahoo.com> Content-Type: text/plain Date: Tue, 19 Apr 2011 20:59:16 -0500 Message-Id: <1303264756.7538.15.camel@darkflame.weatherman.net> Mime-Version: 1.0 X-Mailer: Evolution 2.12.3 (2.12.3-19.el5) Content-Transfer-Encoding: 7bit X-ELNK-Trace: b4d21b641634dbbe40ea0adc697db4f96818e31467099fbae0f2cb4f605ae4cc600bcca8f1f81ff9350badd9bab72f9c350badd9bab72f9c350badd9bab72f9c X-Originating-IP: 66.128.249.226 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.9 tagged_above=-10 required=5 tests=BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001 X-Spam-Level: X-Archive-Number: 201104/179 X-Sequence-Number: 37360 Awesome! Thanks Bob. On Tue, 2011-04-19 at 12:51 -0700, Bob Lunney wrote: > > Slony will use any unique index on a table for replication purposes, so the list of tables should come from: > > select relname > from pg_class c > join pg_namespace n on c.relnamespace = n.oid > where nspname = current_schema() > and relkind = 'r' > and c.oid not in ( > select indrelid > from pg_index > where indisprimary or indisunique > ) > order by 1; > > Bob Lunney > >