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

How to run C# code using mono without Xamarin in Android? -

c# - SharpSsh Command Execution -

python - Specify path of savefig with pylab or matplotlib -