Table of Contents

Enum CascadeTiming

Namespace
Microsoft.EntityFrameworkCore.ChangeTracking
Assembly
Microsoft.EntityFrameworkCore.dll

Defines different strategies for when cascading actions will be performed. See CascadeDeleteTiming and DeleteOrphansTiming.

public enum CascadeTiming

Fields

Immediate = 0

Cascading actions are made to dependent/child entities as soon as the principal/parent entity changes.

Never = 2

Cascading actions are never made automatically to dependent/child entities, but must instead be triggered by an explicit call.

OnSaveChanges = 1

Cascading actions are made to dependent/child entities as part of SaveChanges().

Remarks

See EF Core cascade deletes and deleting orphans for more information and examples.