sergeyksv / tingodb

Embedded Node.js database upward compatible with MongoDB
www.tingodb.com
1.16k stars 105 forks source link

uuid in ObjectId #184

Open amehat opened 4 years ago

amehat commented 4 years ago

Hello,

thank you for this project which is really interesting. As a developer, I generally use uuid to uniquely identify my recordings, is the possibility of using uuid in ObjectId possible with TingoDB natively? And if so, how?

sergeyksv commented 4 years ago

You can use any ids that you want. You only need to put it before inserting record. I mean that there are no constraints that _id is always ObjectId, it can be string, integer etc