Reading the introduction to MongoDB I am a little confused. It seems the Database is made of Collections, which are made of documents, which are made of fields, which are made of key/value pairs. The value can be a document.
To me this seems strange. If a document contains a key/value pair of which the value is the document itself, then it seems the database will explode as it will be infinitely recursive.
I have only just downloaded the database engine and driver so haven't got started preacticing monog yet, but I was just a little perplexed by this statement.
It can be found here http://www.mongodb.org/display/DOCS/Introduction
Could anyone explain how mongodb prevents infinite recursion?
You probably talking about DBRefs. They are just a links to other documents ("addresses" of another do, not documents themselves. You can not read fields of DBRefs like you can for documents, so it basically is "address" of another document, not document itself.