swift - Why core data doesn't delete related objects? -


entities driver , car in 1:many relationship.
in driver entity in relationship table have
relationshipname, car , no inverse
when open table graph style in xcode between entities there 2 arrows on car entity , no arrows on driver entity.
code deleting object:

let somecar:nsmanagedobject = ... let ed = nsentitydescription.entityforname("driver", inmanagedobjectcontext: context!);                 managedobjectcontext?.deleteobject(somecar); context?.save(nil); 

but delete driver car intact.
reason not deleting related objects?


Comments

Popular posts from this blog

Payment information shows nothing in one page checkout page magento -

tcpdump - How to check if server received packet (acknowledged) -