Re: SEARCH and CYCLE clauses

From: Vik Fearing <vik(at)postgresfriends(dot)org>
To: Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: SEARCH and CYCLE clauses
Date: 2020-05-20 13:04:20
Message-ID: 54e533c5-09e5-7f41-9892-d4e0f7c62598@postgresfriends.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 5/20/20 1:46 PM, Peter Eisentraut wrote:
> I have implemented the SEARCH and CYCLE clauses.

YES!

> This is standard SQL syntax attached to a recursive CTE to compute a
> depth- or breadth-first ordering and cycle detection, respectively. This
> is just convenience syntax for what you can already do manually. The
> original discussion about recursive CTEs briefly mentioned these as
> something to do later but then it was never mentioned again.
>
> SQL specifies these in terms of syntactic transformations, and so that's
> how I have implemented them also, mainly in the rewriter.

I've attempted to do this several times but didn't get anywhere with it.
I'm looking forward to reviewing this.

(And maybe it will put me on the right path for implementing <unique
predicate>.)
--
Vik Fearing

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2020-05-20 13:56:55 Re: pgindent vs dtrace on macos
Previous Message Simon Riggs 2020-05-20 12:56:34 Re: Hybrid Hash/Nested Loop joins and caching results from subplans