QuestionQ176

VerifiedData Manipulation

Given that the attached table is stored in a variable named dt:

Question Image

Which LINQ query can return the maximum total Quantity?

Explanation

To determine the maximum total quantity, rows must be grouped by Item, the Quantity values in each group must be summed, and the largest sum must be selected. GroupBy followed by Max over each group’s Sum performs that aggregation.

Community Discussion

No comments yet. Be the first to start the discussion!