asp本周热点sql语句。

来源:百度知道 编辑:UC知道 时间:2024/05/08 12:27:37
asp本周热点sql语句。
按照点击排序。
谢谢。ACCESS数据库。

比如表为:news
字段为: ID title(标题) addtime(添加日期) hits(点击数)
按照你的要求SQL语句就这样写:
sql="select * from news order by hits desc"
这样读出的新闻就是按照点击的高低排列
点击数高的就排在前面~

select * from 表 order by 点击计数字段 desc 从高到低排序
select * from 表 order by 点击计数字段 asc 从低到高

select * from 表 order by 点击计数字段 desc

点击次数多的 在上

SELECT * FROM 表名 ORDER BY 点击率 ASC;