日期字段按年月统计,linq怎么写
2017-05-17
展开全部
linq groupby
var query =
from n in test
group n by new { year = n["year"], month = n["month"] } into g
select new
{
year = g.Key.year,
month = g.Key.month
};
var query =
from n in test
group n by new { year = n["year"], month = n["month"] } into g
select new
{
year = g.Key.year,
month = g.Key.month
};
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询