carbondata-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From watermen <>
Subject [GitHub] incubator-carbondata pull request #618: [CARBONDATA-734] Support the syntax ...
Date Wed, 01 Mar 2017 07:44:16 GMT
GitHub user watermen opened a pull request:

    [CARBONDATA-734] Support the syntax of 'STORED BY PARQUET/ORC'

    When I create parquet table with the command below:
    import org.apache.spark.sql.SparkSession 
    import org.apache.spark.sql.CarbonSession._
    val carbon = SparkSession.builder().config(sc.getConf).getOrCreateCarbonSession("hdfs://")
    carbon.sql("create table src(key int, value string) stored as parquet")
    It will failed with the error info below:
    java.lang.RuntimeException: [1.1] failure: identifier matching regex (?i)ALTER expected
    create table src(key int, value string) stored as parquet
      at scala.sys.package$.error(package.scala:27)
      at org.apache.spark.sql.parser.CarbonSpark2SqlParser.parse(CarbonSpark2SqlParser.scala:45)
      at org.apache.spark.sql.parser.CarbonSparkSqlParser.parsePlan(CarbonSparkSqlParser.scala:51)
      at org.apache.spark.sql.SparkSession.sql(SparkSession.scala:592)
      ... 50 elided
    The reason is if we use `STORED AS`, the value of `value.storageHandler().STRING()` will
be null, so if we still invoke `STRING()`, it will be throw exception.
    cc @jackylk 

You can merge this pull request into a Git repository by running:

    $ git pull CARBONDATA-734

Alternatively you can review and apply these changes as the patch at:

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #618
commit e63ea4b4de08849a9041463584913d189e96b79a
Author: Yadong Qi <>
Date:   2017-03-01T07:26:15Z

    Support the syntax of 'STORED BY PARQUET/ORC'.


If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at or file a JIRA ticket
with INFRA.

View raw message