Re: How does postgres store the join predicate for a relation in a given query

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Gourav Kumar <gourav1905(at)gmail(dot)com>
Cc: Ashutosh Bapat <ashutosh(dot)bapat(at)enterprisedb(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: How does postgres store the join predicate for a relation in a given query
Date: 2017-10-12 17:44:25
Message-ID: 2239.1507830265@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Gourav Kumar <gourav1905(at)gmail(dot)com> writes:
> My objective is to construct join graph from a given query.
> A join graph, has a node for each relation involved in a join, and an edge
> between two relations if they share a join predicate among them.

Hm, well, you could adapt the logic in have_relevant_joinclause() and
have_relevant_eclass_joinclause(). Or maybe you could just use them
as-is ... depends on what you have in mind to do with join clauses
that mention 3 or more relations.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andres Freund 2017-10-12 17:45:44 Re: pgsql: Add configure infrastructure to detect support for C99's restric
Previous Message Robert Haas 2017-10-12 17:29:39 Re: On markers of changed data