Useful MongoDB command
1. Open DB
mongo --host xx.xx.xx.xx [database]
2. Query collections
show collections
3. Export from collection
mongoexport --db [database]--collection [tablename] --o C:\Folder\file.json
mongo --host xx.xx.xx.xx [database]
2. Query collections
show collections
3. Export from collection
mongoexport --db [database]--collection [tablename] --o C:\Folder\file.json
Comments
Post a Comment