ForeignKey.DeleteAction Property
Gets or sets the action taken when the row that is referenced by the foreign key is deleted.
Espace de noms: Microsoft.SqlServer.Management.Smo
Assembly: Microsoft.SqlServer.Smo (in microsoft.sqlserver.smo.dll)
Syntaxe
'Déclaration
Public Property DeleteAction As ForeignKeyAction
public ForeignKeyAction DeleteAction { get; set; }
public:
property ForeignKeyAction DeleteAction {
ForeignKeyAction get ();
void set (ForeignKeyAction value);
}
/** @property */
public ForeignKeyAction get_DeleteAction ()
/** @property */
public void set_DeleteAction (ForeignKeyAction value)
public function get DeleteAction () : ForeignKeyAction
public function set DeleteAction (value : ForeignKeyAction)
Valeur de propriété
A ForeignKeyAction value that specifies the action taken when the row that is referenced by the foreign key is deleted.
Notes
Texte mis à jour :
The DeleteAction property can be used to specify that the action is cascaded. This means that the foreign key row is also deleted. You can also set the foreign key to the default value, or set it to Null.
Cet espace de noms, cette classe ou ce membre est pris en charge uniquement par la version 2.0 de Microsoft .NET Framework.
Exemple
How to: Create, Alter, and Remove a Foreign Key in Visual Basic .NET
Sécurité des threads
Any public static (Shared in Microsoft Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Plateformes
Plateformes de développement
Pour obtenir la liste des plateformes prises en charge, consultez Configuration matérielle et logicielle requise pour l'installation de SQL Server 2005.
Plateformes cibles
Pour obtenir la liste des plateformes prises en charge, consultez Configuration matérielle et logicielle requise pour l'installation de SQL Server 2005.
Voir aussi
Référence
ForeignKey Class
ForeignKey Members
Microsoft.SqlServer.Management.Smo Namespace
Autres ressources
Creating, Altering, and Removing Foreign Keys
Création et modification des contraintes FOREIGN KEY
CREATE TABLE (Transact-SQL)