Skip to content

Instantly share code, notes, and snippets.

@Spaxe
Created November 11, 2011 06:37
Show Gist options
  • Save Spaxe/1357358 to your computer and use it in GitHub Desktop.
Save Spaxe/1357358 to your computer and use it in GitHub Desktop.
Print all available options for MongoDB's db.runCommand()
// Prints all available command from db admin, db.runCommand options
// Usage: mongo < printRunCommandOptions.js
use admin;
for (var cmd in db.getCollection("$cmd")) {
print(cmd);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment