Category "linq"

IEnumerable vs List - What to Use? How do they work?

I have some doubts over how Enumerators work, and LINQ. Consider these two simple selects: List<Animal> sel = (from animal in Animals

Suggestions for designing complex LINQ code

What are your suggestions for designing linq code in project? Especially, I`m interesting in code design of big and complex linq queries? For example, you know,

Union two list by property

I would like to merge two list without duplicates. It should distinct only by one property. I have a class: public class Test { public int Id { get; set;

How can I project into the same DTO type twice?

The goal here is to update an IQueryable that projects into a dto so it only includes a subset of the properties that it originally included. The "subset" is be

How can I project into the same DTO type twice?

The goal here is to update an IQueryable that projects into a dto so it only includes a subset of the properties that it originally included. The "subset" is be