Re: Recursive query syntax ambiguity

From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: Gregory Stark <stark(at)enterprisedb(dot)com>
Cc: PostgreSQL Development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Recursive query syntax ambiguity
Date: 2007-01-26 17:59:49
Message-ID: 45BA4195.2070201@dunslane.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Gregory Stark wrote:
> Woah, I just realized it's much worse than that. I think the syntax in the
> ANSI is not parsable in LALR(1) at all. Note the following:
>
> WITH RECURSIVE foo (a,b) AS (subq) SEARCH BREADTH FIRST BY a,b,c(x,z),d(y,z) AS (subq) SELECT ...
>
> To determine whether "c" is the name of a new <with list element> it has to
> scan as far ahead as the "," before the "d". Note that "d" here is in fact not
> part of the <search clause> at all, it's the name of a second <with list
> element>.
>
> bleagh.
>
>

Can you post the rules you have so far that you're playing around with?
(Also maybe the rules from the standard - I don't have a copy handy).

cheers

andrew

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Pavan Deolasee 2007-01-26 18:44:32 Re: Piggybacking vacuum I/O
Previous Message Jan Wieck 2007-01-26 17:43:54 Re: Proposal: Snapshot cloning