Re: Problems with join (no such attribute, but it exists)

From: Dani Oderbolz <oderbolz(at)ecologic(dot)de>
To: pgsql-novice(at)postgresql(dot)org
Subject: Re: Problems with join (no such attribute, but it exists)
Date: 2003-05-18 12:04:43
Message-ID: 3EC776DB.5030909@ecologic.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: 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

In response to

Browse pgsql-novice by date

  From Date Subject
Next Message Josep Sànchez i Mesegué 2003-05-19 09:43:44 Altering table error
Previous Message Dani Oderbolz 2003-05-18 11:59:39 Re: SELECT database meta-info?