Re: Problems with join (no such attribute, but it exists) - Mailing list pgsql-novice

From Dani Oderbolz
Subject Re: Problems with join (no such attribute, but it exists)
Date
Msg-id 3EC776DB.5030909@ecologic.de
Whole thread Raw
In response to Re: Problems with join (no such attribute, but it exists)  (Manfred Koizar <mkoi-pg@aon.at>)
List pgsql-novice
>
>
>
>BTW, unless one of these tables has only one row, you almost certainly
>want to add a WHERE clause to your query, something like
>
>    WHERE tr.thiscolumn = conv.thatcolumn
>
>Servus
> Manfred
>
>
Hi, this tip from Manfred is very important.
If you do not do that, you will get any possible combinations of
the rows of
the 2 tables, so if both tables have 100 entries, you would get
10000
results,
while most of them don't make any sense.
Think of a join of 3 tables containing 1000 rows each: you would
get a
result of 1000'000'000 rows, this can slow down your server quite
a bit...

Cheers, Dani





pgsql-novice by date:

Previous
From: Dani Oderbolz
Date:
Subject: Re: SELECT database meta-info?
Next
From: Josh Berkus
Date:
Subject: Re: 7.2.1 => 7.3.2