Some questions about CarbonSqlParser

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Some questions about CarbonSqlParser

邢冰
Hi All,


I want to know the internal's of carbondata , recently i read the  CarbonSqlParser class , I just came some questions ?


some parser using hiveql to parse statement , some use scala parser combination for example :
line 289 createTable parser, the implement using  val node = HiveQlWrapper.getAst(statement) to parse create table statement,
line 992 loadDataNew use scala parser combination parser statement
So what's the different of these two implementions ?  can we replace hiveql parser to scala parser ?
 
Thx
Reply | Threaded
Open this post in threaded view
|

回复:Some questions about CarbonSqlParser

杰
Hi,  邢冰


  for create table sql, because it's completely meet hive syntax, so  there is no need to create another parse way.
  for loadData sql, carbon's sql is like LOAD DATA.... INTO .....OPTIONS(...), and OPTIONS is optional. Because hive's syntax has no OPTIONS,
  so we have to create a new parse way to handle carbon load syntax.



regards
Jay


------------------ 原始邮件 ------------------
发件人: "邢冰";<[hidden email]>;
发送时间: 2016年11月23日(星期三) 凌晨0:01
收件人: "dev"<[hidden email]>;

主题: Some questions about CarbonSqlParser



Hi All,


I want to know the internal's of carbondata , recently i read the  CarbonSqlParser class , I just came some questions ?


some parser using hiveql to parse statement , some use scala parser combination for example :
line 289 createTable parser, the implement using  val node = HiveQlWrapper.getAst(statement) to parse create table statement,
line 992 loadDataNew use scala parser combination parser statement
So what's the different of these two implementions ?  can we replace hiveql parser to scala parser ?
 
Thx
Reply | Threaded
Open this post in threaded view
|

回复:回复:Some questions about CarbonSqlParser

邢冰
ok thanks
在2016年11月23日 09:36,Jay 写道:
Hi,  邢冰


 for create table sql, because it's completely meet hive syntax, so  there is no need to create another parse way.
 for loadData sql, carbon's sql is like LOAD DATA.... INTO .....OPTIONS(...), and OPTIONS is optional. Because hive's syntax has no OPTIONS,
 so we have to create a new parse way to handle carbon load syntax.



regards
Jay


------------------ 原始邮件 ------------------
发件人: "邢冰";<[hidden email]>;
发送时间: 2016年11月23日(星期三) 凌晨0:01
收件人: "dev"<[hidden email]>;

主题: Some questions about CarbonSqlParser



Hi All,


I want to know the internal's of carbondata , recently i read the  CarbonSqlParser class , I just came some questions ?


some parser using hiveql to parse statement , some use scala parser combination for example :
line 289 createTable parser, the implement using  val node = HiveQlWrapper.getAst(statement) to parse create table statement,
line 992 loadDataNew use scala parser combination parser statement
So what's the different of these two implementions ?  can we replace hiveql parser to scala parser ?

Thx