[GitHub] [carbondata] zzcclp commented on a change in pull request #3365: [CARBONDATA-3505] Drop database cascade fix

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[GitHub] [carbondata] zzcclp commented on a change in pull request #3365: [CARBONDATA-3505] Drop database cascade fix

GitBox
zzcclp commented on a change in pull request #3365: [CARBONDATA-3505] Drop database cascade fix
URL: https://github.com/apache/carbondata/pull/3365#discussion_r317985662
 
 

 ##########
 File path: integration/spark2/src/main/scala/org/apache/spark/sql/execution/strategy/DDLStrategy.scala
 ##########
 @@ -115,7 +116,7 @@ class DDLStrategy(sparkSession: SparkSession) extends SparkStrategy {
           .setConfigurationToCurrentThread(sparkSession.sessionState.newHadoopConf())
         FileUtils.createDatabaseDirectory(dbName, dbLocation, sparkSession.sparkContext)
         ExecutedCommandExec(createDb) :: Nil
-      case drop@DropDatabaseCommand(dbName, ifExists, isCascade) =>
+      case drop@DropDatabaseCommand(dbName, ifExists, isCascade) if FileFactory.getCarbonFile(CarbonEnv.getDatabaseLocation(dbName, sparkSession)).exists() =>
 
 Review comment:
   move if branch to next line

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[hidden email]


With regards,
Apache Git Services