You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2019/03/01 05:38:20 UTC

[GitHub] dongjoon-hyun commented on a change in pull request #23905: [SPARK-24669][SQL] Refresh table before drop database cascade

dongjoon-hyun commented on a change in pull request #23905: [SPARK-24669][SQL] Refresh table before drop database cascade
URL: https://github.com/apache/spark/pull/23905#discussion_r261483474
 
 

 ##########
 File path: sql/hive/src/test/scala/org/apache/spark/sql/hive/execution/HiveDDLSuite.scala
 ##########
 @@ -2518,4 +2518,38 @@ class HiveDDLSuite
       }
     }
   }
+
+test("SPARK-24669 Refresh table before drop database cascade") {
+    withTempDir { tempDir =>
+      val file1 = new File(tempDir + "/first.csv")
+      val writer1 = new PrintWriter(file1)
+      writer1.write("first")
+      writer1.close()
+
+      val file2 = new File(tempDir + "/second.csv")
+      val writer2 = new PrintWriter(file2)
+      writer2.write("second")
+      writer2.close()
+
+      withDatabase("foo") {
+        sql("create database foo")
+        sql(
+          s"""CREATE TABLE foo.first (id string)
+        using csv options (path='${file1.toURI}')
+      """)
 
 Review comment:
   Indentation (2537 ~ 2539).

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


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org