snuyanzin commented on code in PR #79:
URL: 
https://github.com/apache/flink-connector-jdbc/pull/79#discussion_r1463067119


##########
flink-connector-jdbc/src/test/java/org/apache/flink/connector/jdbc/table/JdbcTablePlanTest.java:
##########
@@ -70,6 +98,51 @@ public void testFilterPushdown() {
                 "SELECT id, time_col, real_col FROM jdbc WHERE id = 900001 AND 
time_col <> TIME '11:11:11' OR double_col >= -1000.23");
     }
 
+    /**
+     * Note the join condition is not present in the optimized plan, as it is 
handled in the JDBC
+     * java code, where it adds the join conditions to the select statement 
string.
+     */
+    @Test
+    public void testLookupJoin() {
+        util.verifyExecPlan(
+                "SELECT * FROM a LEFT JOIN d FOR SYSTEM_TIME AS OF a.proctime 
ON a.ip = d.ip");
+    }
+
+    @Test
+    public void testLookupJoinWithFilter() {

Review Comment:
   ```suggestion
       void testLookupJoinWithFilter() {
   ```



##########
flink-connector-jdbc/src/test/java/org/apache/flink/connector/jdbc/table/JdbcTablePlanTest.java:
##########
@@ -70,6 +98,51 @@ public void testFilterPushdown() {
                 "SELECT id, time_col, real_col FROM jdbc WHERE id = 900001 AND 
time_col <> TIME '11:11:11' OR double_col >= -1000.23");
     }
 
+    /**
+     * Note the join condition is not present in the optimized plan, as it is 
handled in the JDBC
+     * java code, where it adds the join conditions to the select statement 
string.
+     */
+    @Test
+    public void testLookupJoin() {
+        util.verifyExecPlan(
+                "SELECT * FROM a LEFT JOIN d FOR SYSTEM_TIME AS OF a.proctime 
ON a.ip = d.ip");
+    }
+
+    @Test
+    public void testLookupJoinWithFilter() {
+        util.verifyExecPlan(
+                "SELECT * FROM a LEFT JOIN d FOR SYSTEM_TIME AS OF a.proctime 
ON d.type = 0 AND a.ip = d.ip");
+    }
+
+    @Test
+    public void testLookupJoinWithANDAndORFilter() {

Review Comment:
   ```suggestion
       void testLookupJoinWithANDAndORFilter() {
   ```



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

Reply via email to