Received: from localhost (maia-4.hub.org [200.46.204.183]) by postgresql.org (Postfix) with ESMTP id 909909FB1D5 for ; Fri, 26 Jan 2007 08:58:51 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-new, port 10024) with ESMTP id 46150-04 for ; Fri, 26 Jan 2007 08:58:46 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey-1.7.4 Received: from main2.mycybernet.net (main2.mycybernet.net [209.222.63.140]) by postgresql.org (Postfix) with ESMTP id 67A0B9FA589 for ; Fri, 26 Jan 2007 08:58:46 -0400 (AST) Received: from 227-54-222-209.mycybernet.net ([209.222.54.227] helo=phlogiston.dydns.org) by main2.mycybernet.net with esmtp (Exim 4.62) (envelope-from ) id 1HAQq6-0006BC-5L for pgsql-sql@postgresql.org; Fri, 26 Jan 2007 08:09:58 -0500 Received: by phlogiston.dydns.org (Postfix, from userid 1000) id 79E334172; Fri, 26 Jan 2007 07:58:35 -0500 (EST) Date: Fri, 26 Jan 2007 07:58:35 -0500 From: Andrew Sullivan To: pgsql-sql@postgresql.org Subject: Re: LEFT Join Question Message-ID: <20070126125835.GC18845@phlogiston.dyndns.org> References: <34785f060701251551u23538daej2b45f0c522bf1b7a@mail.gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <34785f060701251551u23538daej2b45f0c522bf1b7a@mail.gmail.com> User-Agent: Mutt/1.5.9i X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200701/138 X-Sequence-Number: 27290 On Thu, Jan 25, 2007 at 06:51:34PM -0500, Rob V wrote: > > I know I have to use a left join - but I can seem to figure out the syntax > when dealing w/ different columns of the same table. I haven't tested this to remind myself for sure that it will work, but I think you ought to be able to RIGHT OUTER JOIN the table you just LEFT JOINed to to the next table using a different column. A -- Andrew Sullivan | ajs@crankycanuck.ca Information security isn't a technological problem. It's an economics problem. --Bruce Schneier