List:Internals« Previous MessageNext Message »
From:Peter Gulutzan Date:April 30 2009 4:24pm
Subject:Re: GLOBAL and LOCAL are allowed as labels inside stored routines
View as plain text  
Hi Konstantin,

Konstantin Osipov wrote:
> Hello Peter,
>
> Do you know why SQL-2003 reserved keywords GLOBAL and LOCAL are
> allowed for labels inside stored procedures?
>
> These two keywords in keyword_sp rule case 11 shift/reduce
> conflicts, and seem to be there for no good reason.
>
> Perhaps we should just keep them reserved?
>
> Thanks,
>
> PS The reason I ask is that Antony removes these two from
> keyword_sp rule in his patch for WL#820. This looks like an
> unrelated change, or, perhaps, with addition of external stored
> procedure syntax they started to cause even more conflicts.
>
>   

GLOBAL and LOCAL are not reserved words in MySQL,
so rather than saying "keep them reserved" I would
prefer to say "make them reserved [in future versions]".

We won't soon be supporting the standard-SQL features
that require GLOBAL or LOCAL (in temporary-table declarations,
extended-cursor declarations, time zones, or SET|START
[LOCAL] TRANSACTION), so reserving them now is not urgent
for standard-SQL purposes.

So we'd need to reserve these words only if we accept WL#820.

I have added GLOBAL and LOCAL to the list in WL#4353.

-- 

Peter Gulutzan
Database Group / MySQL www.mysql.com
Sun Microsystems of Canada Inc.
Edmonton, AB, Canada

Thread
GLOBAL and LOCAL are allowed as labels inside stored routinesKonstantin Osipov27 Apr
  • Re: GLOBAL and LOCAL are allowed as labels inside stored routinesPeter Gulutzan30 Apr