lincoln-lil commented on code in PR #20745: URL: https://github.com/apache/flink/pull/20745#discussion_r1033626464
########## flink-table/flink-table-planner/src/test/scala/org/apache/flink/table/planner/runtime/stream/sql/TemporalJoinITCase.scala: ########## @@ -596,16 +596,85 @@ class TemporalJoinITCase(state: StateBackendMode) extends StreamingWithStateTest @Test def testEventTimeTemporalJoinWithNonEqualCondition(): Unit = { + + // test data for Event-Time temporal table join + val rowTimeOrderData = List( + changelogRow("+I", 1L, "Euro", "no1", 12L, "2020-08-15T00:01:00"), + changelogRow("+I", 2L, "US Dollar", "no1", 1L, "2020-08-15T00:02:00"), + changelogRow("+I", 3L, "RMB", "no1", 40L, "2020-08-15T00:03:00"), + changelogRow("+I", 4L, "Euro", "no1", 14L, "2020-08-16T00:04:00"), + changelogRow("-U", 2L, "US Dollar", "no1", 1L, "2020-08-15T00:03:00"), + changelogRow("+U", 2L, "US Dollar", "no1", 18L, "2020-08-16T00:03:00"), + changelogRow("+I", 5L, "US Dollar", "no1", 1L, "2020-08-16T00:03:15"), + changelogRow("+I", 6L, "US Dollar", "no1", 1L, "2020-08-16T00:04:00"), + changelogRow("+I", 7L, "RMB", "no1", 40L, "2020-08-16T00:03:00"), + changelogRow("+I", 8L, "RMB", "no1", 40L, "2020-08-16T00:04:00"), + changelogRow("-D", 8L, "RMB", "no1", 40L, "2020-08-16T00:04:00") + ) + + val rowTimeCurrencyDataUsingBeforeTime = List( + changelogRow("+I", "Euro", "no1", 114L, "2020-08-15T00:00:01"), + changelogRow("+I", "US Dollar", "no1", 122L, "2020-08-15T00:00:02"), + changelogRow("+I", "Yen", "no1", 1L, "2020-08-15T00:00:03"), + changelogRow("+I", "RMB", "no1", 702L, "2020-08-15T00:00:04"), + changelogRow("-U", "Euro", "no1", 114L, "2020-08-15T00:00:01"), + changelogRow("+U", "Euro", "no1", 118L, "2020-08-16T00:01:00"), + changelogRow("-D", "RMB", "no1", 708L, "2020-08-16T00:00:04"), Review Comment: this test data's timestamp '2020-08-16T00:00:04' isn't consistent with the name '...UsingBeforeTime' (should be '2020-08-15T00:00:04'), can we just reuse the common test data `rowTimeCurrencyDataUsingMetaTime` and tables to construct a related filter condition? -- 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: issues-unsubscr...@flink.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org