Поделиться через


Свойство Index.IgnoreDuplicateKeys

Gets or sets the Boolean property value that specifies whether the index ignores duplicate keys.

Пространство имен:  Microsoft.SqlServer.Management.Smo
Сборка:  Microsoft.SqlServer.Smo (в Microsoft.SqlServer.Smo.dll)

Синтаксис

'Декларация
<SfcPropertyAttribute(SfcPropertyFlags.None Or SfcPropertyFlags.Standalone Or SfcPropertyFlags.SqlAzureDatabase Or SfcPropertyFlags.Design Or SfcPropertyFlags.Deploy)> _
Public Property IgnoreDuplicateKeys As Boolean 
    Get 
    Set
'Применение
Dim instance As Index 
Dim value As Boolean 

value = instance.IgnoreDuplicateKeys

instance.IgnoreDuplicateKeys = value
[SfcPropertyAttribute(SfcPropertyFlags.None|SfcPropertyFlags.Standalone|SfcPropertyFlags.SqlAzureDatabase|SfcPropertyFlags.Design|SfcPropertyFlags.Deploy)]
public bool IgnoreDuplicateKeys { get; set; }
[SfcPropertyAttribute(SfcPropertyFlags::None|SfcPropertyFlags::Standalone|SfcPropertyFlags::SqlAzureDatabase|SfcPropertyFlags::Design|SfcPropertyFlags::Deploy)]
public:
property bool IgnoreDuplicateKeys {
    bool get ();
    void set (bool value);
}
[<SfcPropertyAttribute(SfcPropertyFlags.None|SfcPropertyFlags.Standalone|SfcPropertyFlags.SqlAzureDatabase|SfcPropertyFlags.Design|SfcPropertyFlags.Deploy)>]
member IgnoreDuplicateKeys : bool with get, set
function get IgnoreDuplicateKeys () : boolean 
function set IgnoreDuplicateKeys (value : boolean)

Значение свойства

Тип: System.Boolean
A Boolean value that specifies whether the index ignores duplicate keys. If True, the index ignores duplicate keys. Otherwise, False (default).

Замечания

This property controls error generation when an INSERT or UPDATE statement causes a constraint violation because there is a UNIQUE or PRIMARY KEY constraint implemented on the index.

Примеры

Создание, изменение и удаление индексов

См. также

Справочник

Index Класс

Пространство имен Microsoft.SqlServer.Management.Smo

Другие ресурсы

Индексы

CREATE INDEX (Transact-SQL)