Aasawari
(Aasawari Sahasrabuddhe)
3
Hi @Thomas_Hanley and welcome to the MongoDB community forum!!
To query the data from different collection in different database, you can make use of db.getSiblingsDB() to access the other database. However, this command is a mongosh method and cannot be run in the Atlas Data Explorer UI.
If it is not a compulsory requirement, you can move the collection inside the same database and make use of $lookup.
You can visit the $lookup documentation for more information.
Just for further clarification, Atlas Data Lake and Atlas Data Federation (previously called Atlas Data Lake) are different. Would you be able to confirm if Atlas Data Lake is the feature you were looking into? In saying so:
The Data Lake are storage repositories to store the data in its original format.
The MongoDB Atlas Data Federation allows you to query among different MongoDB systems, including Clusters, Databases, and even AWS S3 buckets.
You can read the blog post on Data Lake federation for more information.
Let us know if you have further questions.
Regards
Aasawari
2 Likes