mysql: select * from tablename order by rand() limit 10sqlserver: select top 10 * from tablename order by NEWID()