I\'m trying to load a list of KeyValuePairs from an EF / Linq query like this:
return (from o in context.myTable
select new KeyValuePair
There is also alternative, when you want to store multiple values for one key exists something what is called Lookup.
Represents a collection of keys each mapped to one or more values.
Here you have some official documentations.
More over lookup seems to be much faster than Dictionary < TKey, List < TValue > >.