Using the Mongodb C Driver, how can I issue shell commands like db.mydb.remove()?
The API seems pretty limited: http://api.mongodb.org/c/current/api/annotated.html
Using the Mongodb C Driver, how can I issue shell commands like db.mydb.remove()?
The API seems pretty limited: http://api.mongodb.org/c/current/api/annotated.html
To drop collection use mongo_cmd_drop_collection(…), to drop DBs use mongo_cmd_drop_db(…). Most commands are inside mongo.h.
Edit: To perform the requested remove(…) use mongo_remove(…).