X-Original-To: pgsql-performance-postgresql.org@postgresql.org Received: from localhost (wm.hub.org [200.46.204.128]) by postgresql.org (Postfix) with ESMTP id AC1279FB2B2 for ; Thu, 10 Aug 2006 06:21:01 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.128]) (amavisd-new, port 10024) with ESMTP id 57983-04 for ; Thu, 10 Aug 2006 09:20:57 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey- Received: from nutty.inf.ed.ac.uk (nutty.inf.ed.ac.uk [129.215.216.3]) by postgresql.org (Postfix) with ESMTP id C34069FB2D5 for ; Thu, 10 Aug 2006 06:20:55 -0300 (ADT) Received: from [129.215.218.230] (skibo.inf.ed.ac.uk [129.215.218.230]) by nutty.inf.ed.ac.uk (8.13.6/8.13.6) with ESMTP id k7A9KjIb000405; Thu, 10 Aug 2006 10:20:45 +0100 Message-ID: <44DAFA6D.4070606@inf.ed.ac.uk> Date: Thu, 10 Aug 2006 10:20:45 +0100 From: Sue Fitt User-Agent: Thunderbird 1.5.0.4 (X11/20060620) MIME-Version: 1.0 To: Chris CC: pgsql-performance@postgresql.org Subject: Re: setting up foreign keys References: <44DAE8CF.1030107@inf.ed.ac.uk> <44DAEB04.9050306@gmail.com> <44DAF6B7.1090800@inf.ed.ac.uk> <44DAF8B9.2080000@gmail.com> In-Reply-To: <44DAF8B9.2080000@gmail.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200608/180 X-Sequence-Number: 20365 Well they don't necessarily have the same value! It's a dictionary with cross-referenced words, e.g. 'bring' and 'brought' are both headwords in the dictionary, but 'brought' is cross-referenced to 'bring'. So, the table stores the information (using integer id's rather than words) that bring: bring brought: see bring sing: sing sang: see sing etc. Sue Chris wrote: > Sue Fitt wrote: >> Thanks Chris and Chris, you've solved it. >> >> I had a gui open that connects to the database. It was doing nothing >> (and not preventing me adding to or altering headwords_core via >> psql), but having closed it the table is instantly created. Weird. >> >> BTW, referencing the same column twice is deliberate, it's a >> cross-reference. > > The same column and the same table? > > Same column different table I could understand but not the same column > & table ;) > > I'm sure there's a reason for it though :) >