← Back to team overview

maria-developers team mailing list archive

Re: bb-10.2-compatibility

 

Hello Jerome,

On 03/10/2017 05:58 PM, jerome brauge wrote:
> Hello Alexander,
> 
> Yes, it's your first assumption (works fine in Oracle (as a variable, or a label, or a table alias), but does not work in sql_mode=ORACLE)
> I attached sql scripts used to do these tests (where every keyword are checked individually).
> If you want, I can write the test script for the future patch according to the expected result.

I almost forgot that we already have a task for this:
https://jira.mariadb.org/browse/MDEV-10485

I just moved it as a subtask to "MDEV-10764 PL/SQL parser - Phase 2"


Can you please attach the files that you previously sent by email
(keywords_usage.xlsx and all keywords_xxx.sql) to MDEV-10485?

I could attach them myself, but it's better to have your authorship
for the history.

Many thanks!


> 
> Regards,
> Jérôme.
> 
> 
>> -----Message d'origine-----
>> De : Alexander Barkov [mailto:bar@xxxxxxxxxxx]
>> Envoyé : vendredi 10 mars 2017 12:01
>> À : jerome brauge
>> Cc : maria-developers
>> Objet : Re: bb-10.2-compatibility
>>
>> Hello Jerome,
>>
>> Sorry for a late reply.
>> I was fully busy with the CURSOR FOR LOOP related tasks.
>> Now have time to catch time with my emails.
>>
>>
>> On 03/03/2017 05:17 PM, jerome brauge wrote:
>>> Hello Alexander,
>>>
>>> When I compiled some real procedures, I find some tables alias not
>> supported by the current grammar.
>>> Example :
>>>   create table t1 (col1 int);
>>>   select dec.* from t1 dec;
>>>   select mod.* from t1 mod;
>>>
>>> I have done a complete test on Oracle and Mariadb with all keywords used
>> as variables, table alias and goto/block labels.
>>> You can find result in attached excel file.
>>
>> Thank you very much.
>>
>> Is my understanding correct: "TODO" in some cell means that this keyword
>> works differently in Oracle vs MariaDB's sql_mode=ORACLE?
>>
>> That is:
>>
>> - either works fine in Oracle (as a variable, or a label, or a table alias), but
>> does not work in sql_mode=ORACLE
>> - or, the other way around, it is not allowed in Oracle,
>>   but is accepted by sql_mode=ORACLE?
>> ?
>>
>>
>>>
>>> In addition, schema object names and qualifiers must complied with :
>>>
>> https://docs.oracle.com/cd/B28359_01/server.111/b28286/sql_elements008
>>> .htm#SQLRF00223
>>
>> I have created a task for this:
>>
>> https://jira.mariadb.org/browse/MDEV-12224
>>
>> The most tricky part is to implement regular vs quoted identifiers.
>>
>>>
>>> I tried to add these keywords in rules keyword_directly_assignable,
>> keyword_sp_not_data_type and keyword_sp_data_type, but this generates
>> too many conflicts.
>>> I think that some refactoring of the grammar rules must be done, but I
>> don't know how to do this.
>>
>> Every keyword should be checked individually.
>>
>> By the way, labels should be easy to fix, because they are surrounded by <<
>> and >>, so they should not cause any conflicts at all.
> 
>>
>>
>>
>>>
>>> Regards,
>>> Jérôme.
>>>


Follow ups

References