![](https://img-blog.csdnimg.cn/20201014180756918.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
mybatis
文章平均质量分 59
mybatis、mybatis-plus使用
炎升
这个作者很懒,什么都没留下…
展开
-
mybatis之mapper.xml
一、mapper.xml使用1、<where>标签 如果该标签包含的元素中有返回值,就插入一个where,如果后面的字符串是以and和 or开头,就将他们剔除。<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"&g...原创 2021-05-31 15:56:53 · 10367 阅读 · 0 评论 -
mybatis plus 使用 QueryWrapper总结
1、使用函数QueryWrapper<GeoAssoc> countWrapper = new QueryWrapper<>(); countWrapper.in("parent_geo_id", geoIds); countWrapper.groupBy("parent_geo_id"); countWrapper.select("parent_geo_id as parentGeoId","count(*) as count"); List<Map&l原创 2021-05-28 10:47:55 · 14330 阅读 · 2 评论 -
mybatis-plus 实体注解@TableField、@ApiModel、@ApiModelProperty、@Valid
1、@TableField注解的使用com.baomidou.mybatisplus.annotations.TableField值 描述 value 字段值(驼峰命名方式,该值可无)。如果已开启驼峰映射,则不必在@TableField注解里面写value属性了。 update 预处理 set 字段自定义注入 condition 预处理 WHERE 实体条件自定义运算规则 el 详看注释说明 exist 是否为数据库表字段( 默认 true..原创 2021-05-20 20:47:21 · 4436 阅读 · 0 评论 -
mybatis 总结
1、mapper.xml中SQL处理大于号、小于号:这种问题在xml处理sql的程序中经常需要我们来进行特殊处理。小于 小于等于 大于 大于等于 与 单引号 双引号 < <= > >= & ' " < <= > >= &am...原创 2021-04-29 15:18:45 · 70 阅读 · 0 评论