Rem*_*emy 3 .net linq listview group-by
我有一个嵌套的ListView.有点像这样:http:
//mattberseth.com/blog/2008/01/building_a_grouping_grid_with.html
以下Linq查询:
var query = (from c in context.customer_order
where c.id > 8000
group c by c.person_id into cgroup
select new { cgroup.Key, Orders = cgroup });
Run Code Online (Sandbox Code Playgroud)
我只想在cgroup项中加载一些特定的列.就像通常使用SQL中的"select"语句一样.那可能吗?我在表中有一个blob,如果包含它,它需要很长时间才能加载.
var query = (from c in context.customer_order
where c.id > 8000
group c by c.person_id into cgroup
select new { cgroup.Key, Orders =
from item in cgroup
select new { item.Foo, item.Bar }
});
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
9530 次 |
| 最近记录: |