I have a loop like the following, can I do the same using multiple SUM?
foreach (var detail in ArticleLedgerEntries.Where(pd => pd.LedgerEntryType == LedgerEn
You'd be able to do this pivot-style, using the answer in this topic: Is it possible to Pivot data using LINQ?