24282 пре 1 година
родитељ
комит
83de9c78f5

+ 2 - 2
my-test/src/main/java/org/example/join/domain/QueryColumn.java

@@ -173,11 +173,11 @@ public class QueryColumn implements IFormat, IQueryColumn {
     }
 
     public QueryCondition isNull() {
-        return new QueryCondition(this, SqlConstant.IS_NULL, null);
+        return new QueryCondition(this, SqlConstant.IS_NULL, SqlConstant.IS_NULL);
     }
 
     public QueryCondition isNotNull() {
-        return new QueryCondition(this, SqlConstant.IS_NOT_NULL, null);
+        return new QueryCondition(this, SqlConstant.IS_NOT_NULL, SqlConstant.IS_NULL);
     }
 
     public QueryCondition in(Collection<?> coll) {

+ 17 - 1
my-test/src/test/java/MySpringBootTest.java

@@ -45,8 +45,24 @@ public class MySpringBootTest {
                 .from(sys_dept)
                 .leftJoin(sys_user).on(user_id.eq(dept_id))
                 .where(
+                        create_by.eq(98),
+                        create_by.ne(98),
                         create_by.gt(98),
-                        create_by.lt(98)
+                        create_by.lt(98),
+                        create_by.ge(98),
+                        create_by.le(98),
+                        create_by.between(1, 2),
+                        create_by.notBetween(1, 2),
+                        create_by.like(1),
+                        create_by.notLike(1),
+                        create_by.likeLeft(1),
+                        create_by.notLikeLeft(1),
+                        create_by.likeRight(1),
+                        create_by.notLikeRight(1),
+                        create_by.isNull(),
+                        create_by.isNotNull(),
+                        create_by.in(1, 2, 3, 4),
+                        create_by.notIn(1, 2, 3, 4)
                 )
                 .list();