From: Rob Sargent <robjsargent@gmail.com>
To: Ron <ronljohnsonjr@gmail.com>
Cc: pgsql-general@lists.postgresql.org
Subject: Re: Probably a newbie question
Date: Sat, 10 Aug 2019 13:42:01 -0600
Message-ID: <4CC49DAD-E068-443F-896F-B78F08C99D2C@gmail.com> (raw)
In-Reply-To: <2889ec92-e822-84a6-55af-655688ab9651@gmail.com>
References: <20190810185714.GA23952@panix.com>
<2889ec92-e822-84a6-55af-655688ab9651@gmail.com>
>
> I'd look here:
>
> SELECT
> name
> FROM
> vendor
> WHERE
> bom_item.vendor_key =
> (
> SELECT
> vendor_key
> FROM
> mfg_vendor_relationship
> WHERE
> bom_item.mfg_key = mfg_key
> AND
> prefered = TRUE
> AND
> bom_item.project_key = project_key
>
> )
>
>
> --
> Angular momentum makes the world go ‘round.
You might get away with adding
group by vendor_key
if it turns out you’re simply getting many copies of vendor key from that inner select.
Run it alone to see.
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-general@postgresql.org
Cc: robjsargent@gmail.com, ronljohnsonjr@gmail.com
Subject: Re: Probably a newbie question
In-Reply-To: <4CC49DAD-E068-443F-896F-B78F08C99D2C@gmail.com>
References: <20190810185714.GA23952@panix.com> <2889ec92-e822-84a6-55af-655688ab9651@gmail.com> <4CC49DAD-E068-443F-896F-B78F08C99D2C@gmail.com>
* 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