X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [64.117.224.130]) by svr1.postgresql.org (Postfix) with ESMTP id 4CF29D1F43E for ; Thu, 14 Aug 2003 19:48:26 +0000 (GMT) Received: from svr1.postgresql.org ([64.117.224.193]) by localhost (neptune.hub.org [64.117.224.130]) (amavisd-new, port 10024) with ESMTP id 50713-10 for ; Thu, 14 Aug 2003 16:48:15 -0300 (ADT) Received: from sss.pgh.pa.us (unknown [192.204.191.242]) by svr1.postgresql.org (Postfix) with ESMTP id ACDC6D1C9D5 for ; Thu, 14 Aug 2003 16:47:45 -0300 (ADT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.12.9/8.12.9) with ESMTP id h7EJlH5H007166; Thu, 14 Aug 2003 15:47:17 -0400 (EDT) To: Yuji Shinozaki Cc: pgsql-admin@postgresql.org Subject: Re: copying databases w/ indexes In-reply-to: References: Comments: In-reply-to Yuji Shinozaki message dated "Thu, 14 Aug 2003 15:45:30 -0400" Date: Thu, 14 Aug 2003 15:47:16 -0400 Message-ID: <7165.1060890436@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200308/177 X-Sequence-Number: 9898 Yuji Shinozaki writes: > See my other reply, but the problem was that I had a foreign key > constraint between an integer and varchar. (The column was a varchar and > the foreign key was an integer field). Seems to me postgres shouldn't > have allowed me to do this at all, but I guess it did a slow automatic > type conversion. So, reindexing was deathly slow. There was some talk recently of spitting out a NOTICE when the referenced columns aren't the same type as the referencing columns. It's not done yet, but it's starting to seem like a good idea. regards, tom lane