![](https://img-blog.csdnimg.cn/20201014180756919.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
mysql
艾尔不在
这个作者很懒,什么都没留下…
展开
-
mysql查询json列里面具体的某个属性值
查询一层: SELECT * FROM table WHERE JSON_EXTRACT(request_content, "$.Content") = '1' 说明:JSON_EXTRACT(列名,"$.json某个属性") 查询多层: SELECT * FROM devices WHERE json_extract(json_extract(json_extract(json_data,"$.lastOperation"),"$.target"),"$.name") = '西门门岗闸机01' ..转载 2021-09-01 17:28:06 · 560 阅读 · 0 评论 -
mysql 主键自增不连续
在主键id删除某一条后,再次添加,删除的id不会使用 手动设置让自增加开始于设置的值 alter table t_enterprise auto_increment = 118```原创 2020-12-14 09:59:47 · 122 阅读 · 0 评论 -
Mysql 查询排名
(供自己学习) 查询全部的排名 SELECT obj_new.user_id as userId, obj_new.study_time as studyTime, obj_new.rownum as rank FROM ( SELECT obj.user_id, obj.study_time, @rownum := @rownum + 1 AS num_tmp,原创 2020-12-01 11:34:57 · 88 阅读 · 0 评论