Skip site navigation (1) Skip section navigation (2)

Re: Updatable views/with check option parsing

From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: Martijn van Oosterhout <kleptog(at)svana(dot)org>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Updatable views/with check option parsing
Date: 2006-05-26 21:34:36
Message-ID: 200605262334.36499.peter_e@gmx.net (view raw or flat)
Thread:
Lists: pgsql-hackers
Martijn van Oosterhout wrote:
> Incidently, IIRC the default behaviour on conflict is a shift anyway,
> so that what the patch already does anyway.
>
> So we get:
>
> CREATE VIEW foo AS SELECT expr :: TIME WITH TIME ZONE        <-- OK
> CREATE VIEW foo AS SELECT expr :: TIME WITH CHECK OPTION     <-- > parse error
> CREATE VIEW foo AS SELECT (expr :: TIME) WITH CHECK OPTION   <-- OK

Yes, that's really the fundamental problem if you let shift/reduce
conflicts stand: the parser will behave weirdly in the conflict cases.

There is a seemingly little known option in bison named %glr-parser,
which when turned on parses all of theses cases correctly.  Maybe that
is worth considering.

-- 
Peter Eisentraut
http://developer.postgresql.org/~petere/

In response to

Responses

pgsql-hackers by date

Next:From: Peter EisentrautDate: 2006-05-26 22:23:48
Subject: Re: Updatable views/with check option parsing
Previous:From: Andrew DunstanDate: 2006-05-26 21:26:37
Subject: Re: Updatable views/with check option parsing

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group