I\'ve created a function to save a CoreData entity. The function is called by a loop within another function. The entity is saved, but the relationship is saved only once. Any i