I want to use the example class of mybatis to generate the following sql statement:
SELECT * FROM User where nick_name like "%1502%" or real_name like "%1502%" or mobile like "%1502%"
this is how I used it:
UserExample userExample = new UserExample();
UserExample.Criteria userCriteria = userExample.createCriteria();
userExample.or().andMobileLike("%1502%");
userExample.or().andRealNameLike("%1502%");
userExample.or().andNickNameLike("%1502%");
return userService.selectByExample(userExample);
but using it this way will not return the results I want. It will return all the User data without adding or restrictions
asking for advice