select random id from a table mysql code example
Example: mysql select random id from table
-- randomly order, select first 5 rows
select * from `table_name` order by rand() limit 5
-- randomly order, select first 5 rows
select * from `table_name` order by rand() limit 5