- 博客(6)
- 收藏
- 关注
原创 MySQL5.7.5及以上执行group by报错
MySQL执行报错: [Err] 1055 - Expression #1 of SELECT list is not in GROUP BY clause and contains nonaggregated column 'cerebrum_sit.s.id' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by.
2022-01-12 11:28:49 1343
原创 MySQL中使用Order by排序 遇到null值列的排序情况
排序方法:首先我们需要了解order by 排序的两种情况:1、Order by 字段名 ASC 升序(可以去掉ASC, 默认为升序)2、Order by 字段名 DESC 降序使用场景:当我们使用order by 对某一字段进行排序时,该字段中包含null值,这种情况下,排序就会出现问题,我们可以根据实际情况,指定为空的排在前面或者排在后面实例:我们对某表的默认查询数据sql如下:SELECT id, update_timeFROM...
2022-01-06 19:00:26 9389 1
原创 MybatisPlus使用QueryWrapper调用queryWrapper.last(“limit 1“)时,多次请求该接口后,结尾多出一个“LIMIT 5”
MybatisPlus使用QueryWrapper调用queryWrapper.last("limit 1")时,多次请求该接口后,结尾多出一个“LIMIT 5”,产生了莫名其妙的分页
2021-12-21 19:21:08 10370
原创 mysql出表锁表
spring出现事务锁(com.mysql.cj.jdbc.exceptions.MySQLTransactionRollbackException: Lock wait timeout exceeded; try restarting transaction)
2021-12-21 17:18:20 850
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人