Re: Projection while performing joins.

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Anagh Lal <anaghlal2001(at)yahoo(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Projection while performing joins.
Date: 2003-02-11 05:45:09
Message-ID: 22865.1044942309@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Anagh Lal <anaghlal2001(at)yahoo(dot)com> writes:
> Why do we not just store the attributes required in
> the join (i.e. those in the join qual conditions and
> the ones in the select list) and then perform sorting
> and retrieval on these tuples rather than on the
> possibly larger tuples with more attributes which we
> project out in the end anyway.

We already do --- the scan nodes project out only the needed columns.

At least, that's true in released versions. Just a few days ago I put
a hack into CVS tip to skip the projection step for a scan node that's
not topmost in the plan. As you indicate, that's probably a net loss
when there's a Sort node directly above the scan node. Needs more
thought...

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message SAKAIDA Masaaki 2003-02-11 08:46:20 pgbash-7.3 released
Previous Message Anagh Lal 2003-02-11 04:41:58 Projection while performing joins.