MyBatisPlus ne Method: Not Equal Tutorial
In MyBatisPlus, the not equal to operation can be implemented using the ne method, as shown below:
QueryWrapper<User> queryWrapper = new QueryWrapper<>();
queryWrapper.ne("status", 1); // 不等于1的情况
List<User> userList = userMapper.selectList(queryWrapper);
In the above code, the ‘ne’ method is used to query records where the status field is not equal to 1. In practical use, the appropriate comparison method can be selected based on specific business needs and field types.