Now allows relationships between documents to any depth (grandparent, etc.)

Any depth of relationships
Re-worked foreign key processing for performance