
Hi Greg, As Arman suggested, it could literally be as simple as Dictionary<(key1,key2,key3),List<value>), although creating a list for each entry when duplicate keys are uncommon might be a waste. A second dictionary which only contains the value not in a list Dictionary<(key1,key2,key3),value), could be used initially then fall back to the list dictionary as needed. Wrap it all up in an abstraction to hide the complexity. On Wed, 6 Aug 2025 at 02:14, Arman AZ via ozdotnet <ozdotnet@ozdotnet.com> wrote:
Hi Greg,
Long time no chat...
What I have done is have a list of objects and had multiple dictionaries indexing it. An object that is in a dozen data structures only exists in memory once, so it is cheap to setup the extra indexes. You can get some great performance from it. As soon as you put a database in there, you have to get the data in and out of the database, that can be very time consuming depending on what you are doing.
It sounds like you are going to need an dictionary of lists, to solve the duplicate non-unique key problem.
site: https://ezmusic.ir/ -- ozdotnet mailing list To manage your subscription, access archives: https://codify.mailman3.com/
-- Alan Ingleby