I need help on how to use linq Any with mongodb in c sharp
Following is the query I have written
builder.Where(d => d.DepartmentId == appSettings.ClientId && d.IsCompleted == 0 && d.ScanDate >= fromDate_ && d.ScanDate <= toDate_&&d => op.ProviderLocMappings.Any(pm => d.BatchDocumentEntity.ProviderName.Any(pnm => pnm.Name.Equals(pm.Key) && pnm.Selected == true) && pm.Value.Contains(d.BatchDocumentEntity.Location))).ToList();
It is returning list of documents
But it gives me error unsupported filtered Type Any. Kindly guide me on this how to use Any over here


Answers
Know the answer? Post it. Somebody with the same question will find it here.