lowka commented on code in PR #2857:
URL: https://github.com/apache/ignite-3/pull/2857#discussion_r1410577972


##########
modules/sql-engine/src/test/java/org/apache/ignite/internal/sql/engine/planner/DynamicParametersTest.java:
##########
@@ -301,6 +704,29 @@ public Stream<DynamicTest> testFunction() {
         );
     }
 
+    /** Set operations. */
+    @TestFactory
+    public Stream<DynamicTest> testSetOps() {
+        return Stream.of(
+                sql("SELECT 1 UNION SELECT ?", 1)
+                        .parameterTypes(nullable(NativeTypes.INT32))
+                        .ok(),
+
+                sql("SELECT 1 UNION SELECT ?", Unspecified.UNKNOWN)
+                        .fails("Unable to determine type of a dynamic 
parameter#0."),
+
+                sql("SELECT ? UNION SELECT 1", 1)
+                        .parameterTypes(nullable(NativeTypes.INT32))
+                        .ok(),
+
+                sql("SELECT ? UNION SELECT 1", Unspecified.UNKNOWN)
+                        .fails("Unable to determine type of a dynamic 
parameter#0."),
+
+                sql("SELECT ? UNION SELECT ?", 1, Unspecified.UNKNOWN)
+                        .fails("Unable to determine type of a dynamic 
parameter#1.")

Review Comment:
   Yes for both questions. 



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