读书人

随机取记要

发布时间: 2012-08-29 08:40:14 作者: rapoo

随机取记录

1. Oracle,随机查询20条select * from (  select  *  from 表名 order by dbms_random.value ) where rownum <= 20;  2.MS SQL Server,随机查询20条select top 20  * from  表名order by newid() 3.My SQL:,随机查询20条select  *  from  表名 order by rand() limit 20

?

读书人网 >其他数据库

热点推荐