alekjarmov commented on code in PR #51616:
URL: https://github.com/apache/spark/pull/51616#discussion_r2222720849


##########
sql/core/src/test/scala/org/apache/spark/sql/jdbc/JDBCSuite.scala:
##########
@@ -278,25 +243,50 @@ class JDBCSuite extends QueryTest with SharedSparkSession 
{
     conn.prepareStatement("CREATE TABLE test.partition (THEID INTEGER, `THE 
ID` INTEGER) " +
       "AS SELECT 1, 1")
       .executeUpdate()
-    conn.commit()
 
     conn.prepareStatement("CREATE TABLE test.datetime (d DATE, t 
TIMESTAMP)").executeUpdate()
-    conn.prepareStatement(
-      "INSERT INTO test.datetime VALUES ('2018-07-06', '2018-07-06 
05:50:00.0')").executeUpdate()
-    conn.prepareStatement(
-      "INSERT INTO test.datetime VALUES ('2018-07-06', '2018-07-06 
08:10:08.0')").executeUpdate()
-    conn.prepareStatement(
-      "INSERT INTO test.datetime VALUES ('2018-07-08', '2018-07-08 
13:32:01.0')").executeUpdate()
-    conn.prepareStatement(
-      "INSERT INTO test.datetime VALUES ('2018-07-12', '2018-07-12 
09:51:15.0')").executeUpdate()
-    conn.commit()
 
     conn.prepareStatement(
       "CREATE TABLE test.composite_name (`last name` TEXT(32) NOT NULL, id 
INTEGER NOT NULL)")
       .executeUpdate()
-    conn.prepareStatement("INSERT INTO test.composite_name VALUES ('smith', 
1)").executeUpdate()
-    conn.prepareStatement("INSERT INTO test.composite_name VALUES ('jones', 
2)").executeUpdate()
-    conn.commit()
+
+    val batchStmt = conn.createStatement()
+
+    batchStmt.addBatch("insert into test.people values ('fred', 1)")

Review Comment:
   Yes that's what I am doing.



-- 
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: reviews-unsubscr...@spark.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


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

Reply via email to