Github user QiangCai commented on a diff in the pull request:

    https://github.com/apache/incubator-carbondata/pull/384#discussion_r90745490
  
    --- Diff: 
examples/spark2/src/main/scala/org/apache/carbondata/examples/CarbonExample.scala
 ---
    @@ -17,79 +17,97 @@
     
     package org.apache.spark.sql.examples
     
    +import java.io.File
    +
    +import org.apache.commons.io.FileUtils
     import org.apache.spark.sql.SparkSession
    -import org.apache.spark.util.TableLoader
     
     import org.apache.carbondata.core.constants.CarbonCommonConstants
    +import org.apache.carbondata.core.util.CarbonProperties
     
     object CarbonExample {
     
       def main(args: Array[String]): Unit = {
    -    // to run the example, plz change this path to your local machine path
    -    val rootPath = "/home/david/Documents/incubator-carbondata"
    +    val rootPath = new File(this.getClass.getResource("/").getPath
    +        + "../../../..").getCanonicalPath
    +    val storeLocation = s"$rootPath/examples/spark2/target/store"
    +    val warehouse = s"$rootPath/examples/spark2/target/warehouse"
    +    val metastoredb = s"$rootPath/examples/spark2/target/metastore_db"
    +
    +    // clean data folder
    +    if (true) {
    --- End diff --
    
    this is easy to change to false, if developer want to keep data.


---
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 infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to