geserdugarov commented on code in PR #12245:
URL: https://github.com/apache/hudi/pull/12245#discussion_r1841742431


##########
hudi-spark-datasource/hudi-spark/src/test/scala/org/apache/spark/sql/hudi/dml/TestInsertTable.scala:
##########
@@ -1709,6 +1709,45 @@ class TestInsertTable extends HoodieSparkSqlTestBase {
     }
   }
 
+  test("Test not supported double Bulk Insert Into Bucket Index COW Table") {
+    withSQLConf("hoodie.datasource.write.operation" -> "bulk_insert", 
"hoodie.bulkinsert.shuffle.parallelism" -> "1") {
+      withTempDir { tmp =>
+        val tableName = generateTableName
+        spark.sql(
+          s"""
+             |create table $tableName (
+             |  id int,
+             |  dt string,
+             |  name string,
+             |  price double,
+             |  ts long
+             |) using hudi
+             | tblproperties (
+             | primaryKey = 'id,name',
+             | type = 'cow',
+             | preCombineField = 'ts',
+             | hoodie.index.type = 'BUCKET',
+             | hoodie.index.bucket.engine = 'SIMPLE',
+             | hoodie.bucket.index.num.buckets = '2',
+             | hoodie.bucket.index.hash.field = 'id,name',
+             | hoodie.datasource.write.row.writer.enable = 'false')
+             | partitioned by (dt)
+             | location '${tmp.getCanonicalPath}'
+             """.stripMargin)
+        spark.sql(
+          s"""
+             | insert into $tableName values
+             | (5, 'a1,1', 10, 1000, "2021-01-05")
+             """.stripMargin)
+        checkExceptionContain(
+          s"""
+             | insert into $tableName values

Review Comment:
   Added testing of overwrite operator:
   
https://github.com/apache/hudi/pull/12245/files#diff-2c06898918dddc19f0b90ecd806d81faf88f30d0ae7bb8be509019b6db9c2accR1753



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