美文网首页
mybatis-plus 常用api

mybatis-plus 常用api

作者: 虾米咬小米 | 来源:发表于2020-10-29 16:41 被阅读0次

Mybatis-Plus 只查询某些字段

select

    @Test
    public void selectByWrapper10() {
    list = this.list(new QueryWrapper<AlertSuperviseCorrelationEntity>().select("supervise_department_name").eq("org_id", orgId).groupBy("supervise_department_name"));
    }

Update

UpdateWrapper<User> updateWrapper = new UpdateWrapper<>();
updateWrapper.eq("name","shimin").set("age", 35);

Integer rows = userMapper.update(null, updateWrapper);

相关文章

网友评论

      本文标题:mybatis-plus 常用api

      本文链接:https://www.haomeiwen.com/subject/rbxlvktx.html