How to check all elements in all subfields of a field without explicitly writing the names of the subfields? For example, I have a document like this: {"field": {"sub1": ["IC42", "IC38"], "sub2": ["BH90", "BH70"]}}
, I want something like iterating through all subfields and checking whether any of them has the text “IC42”
I don’t want to use mongodb atlas search because it can produce unexpected results
New contributor