Using two connections with MongoDB using Mongoose with references to different collections

0

I have two MongoDB databases that I connect using Mongoose on NodeJS, one with an X collection that references the ID of another collection Y that is in another MongoDB database on another server.

I need to unify the two databases by copying the X collection according to certain criteria for the database containing the collection Y. Keeping the X collection data up to date on both database servers.

How can I transport a Model from one connection to another?

    
asked by anonymous 17.07.2018 / 00:16

0 answers