Cross Database Populate #938
Unanswered
olawalejuwonm
asked this question in
Q&A
Replies: 1 comment
-
you can always use the second way defined there: pass the Model parameter to the const events = await Event.
find().
// The `model` option specifies the model to use for populating.
populate({ path: 'conversation', model: Conversation }); aside from that, you can also pass the final generated model to the class definition, but if those classes are static / module-global context, then it is not really too-convenient to use, though deferred functions are supported for |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi
Please how do i specify ref as described here: https://mongoosejs.com/docs/populate.html#cross-db-populate for cross database population
Beta Was this translation helpful? Give feedback.
All reactions