Hisoka-X commented on code in PR #9095:
URL: https://github.com/apache/seatunnel/pull/9095#discussion_r2041333014


##########
seatunnel-connectors-v2/connector-iceberg/src/main/java/org/apache/seatunnel/connectors/seatunnel/iceberg/utils/ExpressionUtils.java:
##########
@@ -199,6 +234,17 @@ public static Expression convert(
             }
             return Expressions.equal(column.getColumnName(), 
booleanExpression.isTrue());
         }
+        if (condition instanceof LikeExpression) {
+            LikeExpression expr = (LikeExpression) condition;
+            String columnName = ((Column) 
expr.getLeftExpression()).getColumnName();
+            String value = ((StringValue) 
expr.getRightExpression()).getValue();
+            LikeExpression.KeyWord keyWord = expr.getLikeKeyWord();
+            if (keyWord == LikeExpression.KeyWord.LIKE) {
+                return Expressions.startsWith(columnName, value);

Review Comment:
   We can keep it, and update the doc to tell user we can not support `SELECT * 
FROM t WHERE name LIKE '%John'` which like start with `%`.



-- 
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: commits-unsubscr...@seatunnel.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to