mysql取满足条件的多个结果里一条或者几条最优写法
操作表的大概结构如图 tbl_eumnq_account(id, uss, type, updatetime, ...)SELECT
*
FROM
tbl_eumnq_account
WHERE (
id >= (
(
SELECT
MAX(id)
FROM
tbl_eumnq_account
) - (
SELECT
MIN(id)
FROM
tbl_eumnq_account
)
) * RAND() + (
SELECT
MIN(id)
FROM
tbl_eumnq_account
))
LIMIT 随机几个
页:
[1]