I’ve got a question about the structure of my data, and to see if there is a more efficient way of modifying my data to prevent the use of $lookup. This is a rough structure of my data:
I am using a $lookup on the statics array, each of which map to a StaticSchema on the id field (Essentially a 1:Many relationship). Is it possible to quickly modify the statics array and replace the numeric ids with the ObjectIDs of the StaticSchemas?
Yes. Is there a relationship between the numeric ids and the the ObjectIDs (i.e., numeric id is to be replaced with a corresponding ObjectID)? Or, is it just replacing the whole array with newer one with ObjectIDs?
I’ve got a question about the structure of my data, and to see if there is a more efficient way of modifying my data to prevent the use of $lookup.