alex-plekhanov commented on code in PR #12593:
URL: https://github.com/apache/ignite/pull/12593#discussion_r2648009654


##########
modules/calcite/src/test/java/org/apache/ignite/internal/processors/query/calcite/planner/TableDmlPlannerTest.java:
##########
@@ -190,4 +198,197 @@ public void testDuplicatedColumnNames() throws Exception {
         assertPlan("SELECT CITY.NAME, STREET.NAME FROM STREET JOIN CITY ON 
STREET.CITY_ID = CITY.ID ORDER BY STREET.ID",
             schema, hasColumns("NAME", "NAME1"));
     }
+
+    /** Tests that table modify can be executed on remote nodes. */
+    @Test
+    public void testDistributedTableModify() throws Exception {
+        IgniteSchema schema = createSchema(
+            createTable("TEST", IgniteDistributions.affinity(3, "test", 
"hash"),
+                QueryUtils.KEY_FIELD_NAME, OTHER,
+                QueryUtils.VAL_FIELD_NAME, OTHER,
+                "ID", INTEGER,
+                "AFF_ID", INTEGER,
+                "VAL", INTEGER
+            ),
+            createTable("TEST2", IgniteDistributions.affinity(2, "test2", 
"hash"),
+                QueryUtils.KEY_FIELD_NAME, OTHER,
+                QueryUtils.VAL_FIELD_NAME, OTHER,
+                "ID", INTEGER,
+                "AFF_ID", INTEGER,
+                "VAL", INTEGER
+            ),
+            createTable("TEST3", IgniteDistributions.random(),
+                QueryUtils.KEY_FIELD_NAME, OTHER,
+                QueryUtils.VAL_FIELD_NAME, OTHER,
+                "ID", INTEGER,
+                "AFF_ID", INTEGER,
+                "VAL", INTEGER
+            ),
+            createTable("TEST_REPL", IgniteDistributions.broadcast(),
+                QueryUtils.KEY_FIELD_NAME, OTHER,
+                QueryUtils.VAL_FIELD_NAME, OTHER,
+                "ID", INTEGER,
+                "AFF_ID", INTEGER,
+                "VAL", INTEGER
+            ),
+            createTable("TEST_REPL2", IgniteDistributions.broadcast(),
+                QueryUtils.KEY_FIELD_NAME, OTHER,
+                QueryUtils.VAL_FIELD_NAME, OTHER,
+                "ID", INTEGER,
+                "AFF_ID", INTEGER,
+                "VAL", INTEGER
+            )
+        );
+
+        // Check INSERT statements.
+
+        // partitioned <- values (broadcast).
+        assertPlan("INSERT INTO test VALUES (?, ?, ?)", schema,

Review Comment:
   Actually it's a redundant test even for partitioned table. This case also 
covered by insert as select from broadcast table.



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