Validation Failed: 1: id is too long, must be no longer than 512 bytes

From this closed thread: Id is too long, must be no longer than 512 I understand that _id cannot be longer than 512 bytes. Now I am stuck. Since there isn't a unique constraint for a field I have chosen to use _id. Now the _id cannot be >512 bytes. Why is there this limit? Seems arbitrary. Yes I know that >512 bytes for an _id is long, blah, blah, blah. But if I want >512 bytes why not?

Can we remove the limit and just put in the docs a note that shorter id's are better? It is a small index and performance isn't too important.

My solution was to use the original _id hash value .

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.