Indhumathi27 commented on a change in pull request #4186:
URL: https://github.com/apache/carbondata/pull/4186#discussion_r679658420



##########
File path: 
integration/spark/src/main/scala/org/apache/spark/sql/execution/strategy/DDLHelper.scala
##########
@@ -52,15 +54,16 @@ object DDLHelper {
     ThreadLocalSessionInfo
       
.setConfigurationToCurrentThread(sparkSession.sessionState.newHadoopConf())
     if (!EnvHelper.isLegacy(sparkSession)) {
-      val databaseName = createDatabaseCommand.databaseName
-      val dbLocation = try {
-        CarbonEnv.getDatabaseLocation(databaseName, sparkSession)
-      } catch {
-        case _: NoSuchDatabaseException =>
-          CarbonProperties.getStorePath
+      val carbonStorePath = CarbonProperties.getStorePath()
+      val sparkWarehouse = sparkSession.conf.get("spark.sql.warehouse.dir")
+      if (StringUtils.isNotEmpty(carbonStorePath) && 
StringUtils.isNotEmpty(sparkWarehouse)

Review comment:
       do we need to fail it, when user fires create database with location ? i 
think, i that case, no need to check this




-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to