Delen via


UniqueConstraintDefinition.IsPrimaryKey Property

Gets or sets whether the constraint is both unique and a primary key.

Namespace:  Microsoft.SqlServer.TransactSql.ScriptDom
Assembly:  Microsoft.SqlServer.TransactSql.ScriptDom (in Microsoft.SqlServer.TransactSql.ScriptDom.dll)

Syntax

'Declaration
Public Property IsPrimaryKey As Boolean 
    Get 
    Set
'Usage
Dim instance As UniqueConstraintDefinition 
Dim value As Boolean 

value = instance.IsPrimaryKey

instance.IsPrimaryKey = value
public bool IsPrimaryKey { get; set; }
public:
property bool IsPrimaryKey {
    bool get ();
    void set (bool value);
}
member IsPrimaryKey : bool with get, set
function get IsPrimaryKey () : boolean 
function set IsPrimaryKey (value : boolean)

Property Value

Type: System.Boolean
True if the constraint is both unique and a primary key; otherwise, false.

See Also

Reference

UniqueConstraintDefinition Class

Microsoft.SqlServer.TransactSql.ScriptDom Namespace