Page History
...
Code Block | ||||
---|---|---|---|---|
| ||||
mongo --host psanaphi105 --port 27017 To exit the shell, type quit() or use the <Ctrl-C> shortcut. > db test > show dbs admin 0.000GB calib-cxif5315 0.006GB config 0.000GB local 0.000GB > use calib-cxif5315 switched to db calib-cxif5315 > show collections cspad-0-cxids1-0 cspad-1 > db["cspad-0-cxids1-0"].find() > db["cspad-0-cxids1-0"].find().pretty() # Delete databale: use calib-cxif5315 db.dropDatabase() # Delete collection db.collection.drop() # OR: db["cspad-0-cxids1-0"].drop() > help # Export/backup database in file > help mongodump -d <dbname> --archive <filename> --out /path/to/backup/dir # Import database from file mongorestore -d <dbname> --archive <filename> |
Connection to DB in python
...
Overview
Content Tools