MongoDB Copy Database
Use
Syntax:
Examples:
Copy Database on Same Instance
You can create a duplicate database in the same instance by using copyDatabase() function.
Output:
Also, you can use the above option to rename database in MongoDB. But you must have enough space to create a copy of an existing database with a different name. After that, you can remove the old database to release space.
Copy Database from Remote Instance
You can also use
The above command will show a large output on your screen as per available documents in the database.
0 Comments
CAN FEEDBACK
Emoji