Basically I need to use $arrayToObject but I don't see how I can use it with LINQ. Is there a way to create a LINQ query using mongo driver that would generate above aggregation step?
This is the example aggregation pipeline step:
{
$project: {
tmp:{$arrayToObject:
{$zip:{inputs:
["$items.TypeCode","$items.Value"]}}}
}
}