I have retrieving data from DB which is something like that
ID - item ID - State - type - comment
===
1 - 158 - 0 - 114589- AAAAA
2 - 158 - 1 - 108965- BBBBB
3 - 159 - 1 - 100145- CCCCC
4 - 159 - 0 - 100145- DDDDD
5 - 159 - 1 - 114589- EEEEE
6 - 162 - 0 - 100145- FFFFF
7 - 162 - 1 - 108965- GGGGG
I need to return the result select item ID ,count the State grouped by item ID, state , type and comment
how can I do this using LINQ?
1 Answer