数据库录----sql获取第一条数据top用法简述

TOP 子句用于规定要返回的记录的数目,下面是不同数据库top的用法

mySQL用法:select * from table LIMIT 1

oracle用法:select * from table where rownum=1
sqlserver用法:select top 1 * from table 
posted @ 2016-01-19 12:31  孙振光  阅读(261)  评论(0)    收藏  举报