【发布时间】:2010-04-29 11:42:12
【问题描述】:
一个简单的问题,可能容易回答,也可能不容易回答。
目前,为了使用 SubSonic 将有限的数据结果集返回给我的调用引用,我使用了如下类似的函数:
_DataSet = from CatSet in t2_aspnet_shopping_item_category.All()
join CatProdAssignedLink in t2_aspnet_shopping_link_categoryproduct.All() on CatSet.CategoryID equals CatProdAssignedLink.CategoryID
join ProdSet in t2_aspnet_shopping_item_product.All() on CatProdAssignedLink.ProductID equals ProdSet.ProductID
where ProdSet.ProductID == __ProductID
orderby CatProdAssignedLink.LinkID ascending
select CatSet;
并从数据集中选择第一项。
有没有办法将查找最初限制为一定数量的行?我使用 MySQL 作为基础数据库。
【问题讨论】:
标签: mysql linq subsonic3 limit