-
Type: New Feature
-
Resolution: Unresolved
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
-
Query Execution
I have been working with MongoDB for quite some time and I find that with the proper schema design, it can fit most generic use cases.
However there are cases where referencing between collections (SQL like) is unavoidable. In these cases, the biggest drawback with Mongo compared to SQL DBs is the foreign key constraint inability.
Even checking using application logic, isn't 100% correct, since if you check for the validity of the field value before inserting the document, you can't be sure that it wasn't deleted when you create it and you have to check after creation and apply compensating deletion - error handling.
I believe an index functionality where it would assert the existence of the field's value in an other's collection index would be extremely helpful and remove this major drawback of Mongo compared to sequential databases, since the check in the database level would allow for proper foreign key constraint.
Tried to find similar issues - feature requests but didn't find any, that's why I created this one.
Any thoughs on that?