Table:
ID State Rate
2 NY 8
1 CA 10
1 NY 9
2 IL 7
2 WA 8
1 WA 5
Linq Result Table:
ID State ApprovedR Not-ApprovedR
2 NY 8 9
1 CA 0 10
2 IL 7 0
2 WA 8 5
Rate with record of ID=1 is considered as Not-ApprovedR,
If a record doesn't have and ID of 1 then its Not-ApprovedR should be shown as 0
ID = 1which you say should have itsRatein theNot-ApprovedRcolumn, yet that is not what the 2nd table shows (its in theApprovedRcolumnApprovedRorNot-ApprovedRset to0right? *Edit: You kinda need to define your requirements clearly in your post and try showing what have you tried so far.2even though one of those records hasID = 1- why is the value not1for example (surely that column should be omitted)