pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Dan Langille <match@langille.org>
To: DI Hasenöhrl <i.hasenoehrl@aon.at>
Cc: pgsql-sql@postgresql.org
Subject: Re: Left outer join with WHERE clause?
Date: Thu, 28 Mar 2002 08:10:21 -0500
Message-ID: <20020328130950.481C03F2D@bast.unixathome.org> (raw)
In-Reply-To: <002b01c1d658$4612fc40$01011eac@irina>

On 28 Mar 2002 at 13:58, DI Hasenöhrl wrote:

> It doesn't work too:            LEFT JOIN (vartikellieferantbez ON
> artikel.a_nr = vartikellieferantbez.a_nr WHERE
> ((vartikellieferantbez.f_nr)=1)

Your "where" clause for an OUTER JOIN is actually the ON statement.  So do this:

LEFT JOIN (vartikellieferantbez ON (artikel.a_nr = vartikellieferantbez.a_nr  AND
vartikellieferantbez.f_nr = 1))




view thread (6+ messages)  latest in thread

Message-ID: <20020328130950.481C03F2D@bast.unixathome.org>
Permalink:  ../20020328130950.481C03F2D@bast.unixathome.org/
Also on:    postgresql.org/message-id/20020328130950.481C03F2D@bast.unixathome.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: match@langille.org, i.hasenoehrl@aon.at
  Subject: Re: Left outer join with WHERE clause?
  In-Reply-To: <20020328130950.481C03F2D@bast.unixathome.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox