Skip to content

Instantly share code, notes, and snippets.

@icoxfog417
Last active December 16, 2015 13:09
Show Gist options
  • Save icoxfog417/5439742 to your computer and use it in GitHub Desktop.
Save icoxfog417/5439742 to your computer and use it in GitHub Desktop.
LINQ from DataTable and Group by
From row In listData.AsEnumerable
Group row By _
NAME = row.Field(Of String)("NAME") _
Into g = Group
Let SCORE = g.Sum(Function(row) row.Field(Of Integer)("SCORE"))
Select NAME,SCORE
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment