From: Shaukat Mahmood Ahmad Date: November 30 2012 3:02pm Subject: Re: question about UDF List-Archive: http://lists.mysql.com/internals/38641 Message-Id: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 One little explanation: you cant introduce new keywords by simply adding them to sql/lex.h, you will have to write grammar for new reserve words / commands, and then will have to regenerate sql parser using gnu bison ( that is a parser generator tool). Regards, Shaukat Mahmood Ahmad On Fri, Nov 30, 2012 at 7:48 PM, Shaukat Mahmood Ahmad wrote: > One little explanation: you cant introduce new keywords by simply adding > them to sql/lex.h, you will have to write grammar for new reserve words / > commands, and then will have to regenerate sql parser using gnu bison ( > that is a parser generator tool). > > Regards, > Shaukat Mahmood Ahmad > > > On Fri, Nov 30, 2012 at 12:13 PM, Michael Widenius > wrote: >> >> >> Hi! >> >> >>>>> "Zhixuan" == Zhixuan Zhu writes: >> >> Zhixuan> Hi, >> Zhixuan> I have two questions: >> >> Zhixuan> 1. Is there a way that I can add customized reserved words to >> mysql? >> >> Yes, by adding them to sql/lex.h >> >> >> Zhixuan> 2. Is it possible that I can use the customized reserve words in >> my udf >> Zhixuan> function? >> >> No. You would get a syntax error when using the reserved word as the >> parser would not know what to do with the word. >> >> Regards, >> Monty >> Creator of MySQL and MariaDB >> >> >> -- >> MySQL Internals Mailing List >> For list archives: http://lists.mysql.com/internals >> To unsubscribe: http://lists.mysql.com/internals >> >