X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 1D500D1B238 for ; Wed, 9 Jun 2004 02:04:59 -0300 (ADT) 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 79462-08 for ; Wed, 9 Jun 2004 05:04:55 +0000 (GMT) Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by svr1.postgresql.org (Postfix) with ESMTP id 261B0D1B1A1 for ; Wed, 9 Jun 2004 02:04:53 -0300 (ADT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.12.11/8.12.11) with ESMTP id i5954ll7016090; Wed, 9 Jun 2004 01:04:48 -0400 (EDT) To: Kyle Cc: pgsql-sql@postgresql.org, Peter Eisentraut Subject: Re: Getting FK relationships from information_schema In-reply-to: <40C5D790.6090407@actarg.com> References: <40C500D8.9060009@actarg.com> <26677.1086673982@sss.pgh.pa.us> <40C5D790.6090407@actarg.com> Comments: In-reply-to Kyle message dated "Tue, 08 Jun 2004 09:13:20 -0600" Date: Wed, 09 Jun 2004 01:04:47 -0400 Message-ID: <16089.1086757487@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200406/64 X-Sequence-Number: 18009 Kyle writes: > I think this is only an issue when the user relies on postgres to choose > a constraint name automatically. Seems like a reasonable approach would > be to have postgres choose a name for the constraint that happens to be > unique in the schema (like tablename_fkey_$1). We have discussed changing the default names of FK constraints before. I have no problem with doing something like the above --- any objection out there? (Of course, this is only a long-term fix for your original problem, as it'll take a good long while for any such naming change to propagate to Joe's-Corner-Bar's database.) regards, tom lane