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

Peripheral Links

Header And Logo

PostgreSQL
| The world's most advanced open source database.

Site Navigation

Search for
  Advanced Search

Re: Updatable views/with check option parsing


  • From: "Andrew Dunstan" <andrew(at)dunslane(dot)net>
  • To: <peter_e(at)gmx(dot)net>
  • Cc: <kleptog(at)svana(dot)org>, <pgsql-hackers(at)postgresql(dot)org>
  • Subject: Re: Updatable views/with check option parsing
  • Date: Fri, 26 May 2006 16:26:37 -0500 (CDT)
  • Message-id: <1762(dot)24(dot)211(dot)165(dot)134(dot)1148678797(dot)squirrel(at)www(dot)dunslane(dot)net>

Peter Eisentraut said:
> 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.

Interesting.

Unfortunately, the manual says:

"The GLR parsers require a compiler for ISO C89 or later. In addition, they
use the inline keyword, which is not C89, but is C99 and is a common
extension in pre-C99 compilers. It is up to the user of these parsers to
handle portability issues."

Do we want such a restriction?

cheers

andrew







Home | Main Index | Thread Index

Privacy Policy | PostgreSQL Archives hosted by Command Prompt, Inc. | Designed by tinysofa
Copyright © 1996 – 2008 PostgreSQL Global Development Group