按日期統計 某天 發貼最多多少條
select top 1 count(*) as max from bbs group by convert(varchar(10),realeasedate,120) order by max desc
當天發了多少條
String date=DateUtil.convertStrToTimestamp(new Date()).toString().substring(0,10);
String sql="select count(bbsid) from bbs where convert(varchar(21),realeasedate,120) like '"+date+"%'";
posted on 2009-04-10 16:52
Crying 閱讀(150)
評論(0) 編輯 收藏 所屬分類:
數據庫