摘要:
一、根据id删除 @Test public void deleteById() { int rows = userMapper.deleteById(1351456313578713090L); System.out.println("删除条数:" + rows); } @Test public v 阅读全文
摘要:
一、根据id更新 @Test public void updateById() { User user = new User(); user.setId(1088248166370832385L); user.setAge(26); user.setEmail("wtf2@baomidou.com" 阅读全文
摘要:
一、普通查询 @SpringBootTest public class QueryTest { @Autowired private UserMapper userMapper; @Test public void selectById() { User user = userMapper.sele 阅读全文
摘要:
一、快速入门 1、建库建表 #创建用户表 CREATE TABLE user ( id BIGINT(20) PRIMARY KEY NOT NULL COMMENT '主键', name VARCHAR(30) DEFAULT NULL COMMENT '姓名', age INT(11) DEFA 阅读全文