AMashenkov commented on code in PR #5838: URL: https://github.com/apache/ignite-3/pull/5838#discussion_r2095431537
########## modules/jdbc/src/integrationTest/java/org/apache/ignite/jdbc/ItJdbcResultSetSelfTest.java: ########## @@ -96,6 +98,35 @@ public static void beforeClass() throws SQLException { } } + @Test + public void testIntervalResult() throws SQLException { + assertEquals(Duration.ofDays(4), eval("INTERVAL 4 DAYS")); + assertEquals(Duration.ofSeconds(1), eval("INTERVAL 1 SECONDS")); + assertEquals(Duration.ofSeconds(-1), eval("INTERVAL -1 SECONDS")); + assertEquals(Duration.ofSeconds(123), eval("INTERVAL 123 SECONDS")); + assertEquals(Duration.ofSeconds(123), eval("INTERVAL '123' SECONDS(3)")); + assertEquals(Duration.ofMinutes(2), eval("INTERVAL 2 MINUTES")); + assertEquals(Duration.ofHours(3), eval("INTERVAL 3 HOURS")); + assertEquals(Duration.ofDays(4), eval("INTERVAL 4 DAYS")); + assertEquals(Period.ofMonths(5), eval("INTERVAL 5 MONTHS")); + assertEquals(Period.ofMonths(-5), eval("INTERVAL -5 MONTHS")); Review Comment: SQL standard says `Within a value of type interval, the first field is constrained only by the <interval leading field precision>` which is unsigned integer. -- 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: notifications-unsubscr...@ignite.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org