AssociationAttribute.DeleteRule 속성

정의

연결에 대한 삭제 동작을 가져오거나 설정합니다.

public:
 property System::String ^ DeleteRule { System::String ^ get(); void set(System::String ^ value); };
public string DeleteRule { get; set; }
member this.DeleteRule : string with get, set
Public Property DeleteRule As String

속성 값

규칙을 나타내는 문자열입니다.

예제

[Association(Name="FK_Products_Categories", Storage="_Products", OtherKey="CategoryID", DeleteRule="NO ACTION")]
public EntitySet<Product> Products
{
    get
    {
        return this._Products;
    }
    set
    {
        this._Products.Assign(value);
    }
}
<Association(Name:="FK_Products_Categories", Storage:="_Products", OtherKey:="CategoryID", DeleteRule:="NO ACTION")>
Public Property Products() As EntitySet(Of Product)
    Get
        Return Me._Products
    End Get
    Set
        Me._Products.Assign(Value)
    End Set
End Property

설명

null로 설정하면 삭제 동작이 추가되지 않습니다. 예를 들어 "CASCADE"는 외래 키 관계에 "ON DELETE CASCADE"를 추가합니다.

다음 예제에서 규칙은 아무 작업도 수행하지 않습니다.

적용 대상