amark / mongous

Simple MongoDB driver for Node.js with jQuery like syntax.
MIT License
246 stars 30 forks source link

last insert id? #26

Open catindev opened 12 years ago

catindev commented 12 years ago

how can I get it?

amark commented 11 years ago

@baddcat, sorry for a late reply. Apparently GitHub stopped sending me emails about issues!

You can do a find() query on the object you just saved/updated and retrieve it there.

If you do not have that object to query against? I'm currently not sure how to do this in the Mongo shell itself. If you could tell me how (if it is possible) to do it there, I can probably provide a better answer.

I'm gonna leave this open, but if I don't hear back from you in a while, I'm gonna close it.