When defininng the to be returned fields (collection.find(q, fields))
, does (how does) mongoDB support to compare the field names (and not the value)?
E.g. to select a range of fields based on their name without regard to their value.
Assume the following fields (whatever the value might be) in a document:
fieldA000 fieldA001 fieldA002 fieldB000 fieldB001 fieldC000 ...
and I want to restrict the returned fields for any field name matching fieldA000 to fieldA999
(without need to define explicitely any field name) or fieldA.*
(reg ex) or similar.
P.S.: I am currently evaluating whether we could use mongoDB instead of Cassandra where the column-range/slice-select is provided in a very easy to use way.