❔ How to join 3 collections?
I have following logic:
I'd like to join accessGroups, departments, subjects, and get some properties from that collections
How can I do it?
6 Replies
Also I need to group by territory
If you wish to perform an SQL like join, try this:
source: https://www.reddit.com/r/csharp/comments/mxvsoj/comment/gvrpzvl/?utm_source=share&utm_medium=web2x&context=3
reddit
r/csharp - Comment by u/ropewalker on ”Linq pairing two Lists of ...
16 votes and 10 comments so far on Reddit
You can use the
.Join
extension method to combine two lists into a new list of a different type, e.g., a value tuple. After performing your joins you can select the properties that you need, group, whateverbut I have 3 lists
so first join a and b
then join the result with c
Was this issue resolved? If so, run
/close
- otherwise I will mark this as stale and this post will be archived until there is new activity.