浏览:529 2008-01-28 15:32 来自 52Qin      :
Gateway.default.From<News_Content>().Where(News_Content._.News_CateID==cate­).OrderBy(News_Content._.News_Content_Uptime.Desc).ToArray<News_Content>(to­p);

把新闻内容,按News_CateID分类,然后排序,取top个.返回

 From,Where,OrderBy ,再TOP,不能取得TOP,而是全部的内容.不知道为什么?

 

收藏 楼主
  8个月前  52Qin      :
Gateway.default.From().Where(News_Content._.News_CateID==3).OrderBy(News_Content._.News_Content_Uptime.Desc).ToArray(10);
把分类为3的,按时间倒叙,取得前10个.
1楼 回到顶楼 
  8个月前  52Qin      :
返回的是整个分类为3的,倒叙,前10没有起作用.
2楼 回到顶楼 

注册用户登录后才能回复,登录注册
> 返回“NBear”


其他话题

相关内容

相关链接

1 26419