时间:2021-07-01 10:21:17 帮助过:33人阅读
SELECT * FROM `table` AS t1 JOIN (SELECT ROUND(RAND() * ((SELECT MAX(id) FROM `table`)-(SELECT MIN(id) FROM `table`))+(SELECT MIN(id) FROM `table`)) AS id) AS t2 WHERE t1.id >= t2.id ORDER BY t1.id LIMIT 1;
< 上一篇
SQL查询动态占位符
下一篇 >
pt-online-schema-change进行MySQL表的主键变更
记住我的登录 忘记密码?
登录
我已阅读用户协议及版权声明
注册