Ühel kenal päeval, K, 2006-05-24 kell 13:13, kirjutas Peter Eisentraut:
> I have spent some time figuring out how to resolve the parsing conflicts in 
> Bernd Helmle's updatable views patch.  The problem has now been reduced to 
> specifically this situation:
> 
> CREATE VIEW foo AS SELECT expr :: TIME . WITH
> 
> (where expr is a_expr or b_expr and TIME could also be TIMESTAMP or TIME(x) 
> or 
> TIMESTAMP(x)).
> 
> The continuation here could be WITH TIME ZONE (calling for a shift) or WITH 
> CHECK OPTION (calling for a reduce).
> 
> All the usual ideas about unfolding the rules or making keywords more 
> reserved 
> don't work (why should they).  A one-token lookahead simply can't parse this.

Can't we teach tokenized a new token "WITH TIME ZONE" ?

> I have had some ideas about trying to play around with the precedence rules 
> -- 
> giving WITH TIME ZONE a higher precedence than WITH CHECK OPTION -- but I 
> have no experience with that and I am apparently not doing it right, if that 
> is supposed to work at all.
> 
> If we can't get that to work, it seems that we are out of options unless we 
> want to just accept the conflicts.
> 
> How should we go about this, and what should Bernd do with his patch, which, 
> as I understand it, has been held up for quite a while simply because he is 
> concerned about this issue?
> 
-- 
----------------
Hannu Krosing
Database Architect
Skype Technologies OÜ
Akadeemia tee 21 F, Tallinn, 12618, Estonia

Skype me:  callto:hkrosing
Get Skype for free:  http://www.skype.com



---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?

               http://www.postgresql.org/docs/faq

Reply via email to