Skip to content

Instantly share code, notes, and snippets.

@glamp
Created April 10, 2013 22:49
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 glamp/5359149 to your computer and use it in GitHub Desktop.
Save glamp/5359149 to your computer and use it in GitHub Desktop.
--MongoDB or other databases
select
'db.foo.findOne({_id: ObjectId("' || _id || '")})'
from foo;
--db.foo.find({_id: ObjectId("5066fa4abd8ad53408a4869c")})
--web based (great for spidering)
select
'http://www.yelp.com/search?find_loc=Manhattan%2C+NY&ns=1&find_desc=' || name as url
from
restaurants;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment