LINQ SelectMany in Depth
In this article, I’ll walk through the various overloads and usages of LINQ’s
SelectMany is in many ways the opposite of
GroupBy which I covered last time in this series on LINQ. While
GroupBy took a single collection and transformed it into multiple child collections,
SelectMany flattens child collections into a single merged collection.
So, how is this flattening actually useful?