mongous
mongous copied to clipboard
last insert id?
how can I get it?
@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.