Re: bug in JOIN or COUNT or ... ? - Mailing list pgsql-hackers

From The Hermit Hacker
Subject Re: bug in JOIN or COUNT or ... ?
Date
Msg-id Pine.BSF.4.33.0105122237300.629-100000@mobile.hub.org
Whole thread Raw
In response to Re: bug in JOIN or COUNT or ... ?  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: bug in JOIN or COUNT or ... ?  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On Sat, 12 May 2001, Tom Lane wrote:

> Ah, I see it: your join against relationship_wanted isn't unique.
>
> globalmatch=# select count(*) from personal_data pd
> globalmatch-# where pd.gid = 17111 AND pd.gender = 0;
>  count
> -------
>      1
> (1 row)
>
> globalmatch=# select count(*) from relationship_wanted rw
> globalmatch-# where rw.gid = 17111 AND rw.gender = 0;
>  count
> -------
>      5
> (1 row)
>
> globalmatch=#
>
> So that inflates the number of rows coming out of the join by 5.

Okay, then I'm lost ... why wouldn't that show up without the COUNT()?  I
doubt doubt your analysis, I just want to understand why ...



pgsql-hackers by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: 7.2 items
Next
From: The Hermit Hacker
Date:
Subject: Re: bug in JOIN or COUNT or ... ?