Skip to content

Instantly share code, notes, and snippets.

@shanestillwell
Created December 20, 2012 20:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save shanestillwell/4348419 to your computer and use it in GitHub Desktop.
Save shanestillwell/4348419 to your computer and use it in GitHub Desktop.
Finding MongoDB array that is NOT empty but exists
db.device.find({​"deviceTokens":{"$not":{"$size":0},$exists: 1}});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment