Replies: 1 comment 1 reply
-
Mongoose's |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello!
I am trying to retrieve documents using the lookup operator during aggregation in MongoDB. However, the "from" field in the lookup operator does not allow dynamic values such as in-schema variables. From what I have found, it must be a string literal. However, in Mongoose, we can create dynamic references using the "refPath" field.
My question is, how does the mechanism behind this dynamic referencing work in Mongoose? Is there any way to implement the same approach in the MongoDB aggregation pipeline?
Thank you for your help.
Beta Was this translation helpful? Give feedback.
All reactions