AMashenkov commented on code in PR #2857:
URL: https://github.com/apache/ignite-3/pull/2857#discussion_r1410576226
##########
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:
You have a test that expects INT32 type, but here is a Long (INT64).
Will and should this work?
If a type make no sense in this test. Just skip my comment.
--
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]