IMetabaseUpdateDataObjectNode.ReferenceConstraintsHandling

Syntax

ReferenceConstraintsHandling: UpdateDataConstraintsHandlingType;

Description

The ReferenceConstraintsHandling property determines method of limitation of integrity of updating object elements.

Comments

This property is relevant for the update of MDM dictionaries, which elements may have the links from other dictionaries.

Example

Executing the example requires an MDM repository with the NSI_1 identifier. The current repository contains the Dict_1 MDM dictionary.

Sub Main;

Var

MB: IMetabase;

MBDesc: IMetabaseObjectDescriptor;

MUpdate: IMetabaseUpdate;

ObjNode: IMetabaseUpdateDataObjectNode;

Begin

MB := MetabaseClass.Active;

//The dictionary being updated

MBDesc := MB.ItemByIdNamespace("Dict_1", MB.ItemById("NSI_1").Key);

MUpdate := MB.CreateUpdate;

ObjNode := MUpdate.RootFolder.Add(MetabaseUpdateNodeType.DataObject) As IMetabaseUpdateDataObjectNode;

ObjNode.Label := MBDesc.Id;

ObjNode.Method := MetabaseUpdateMethod.All;

ObjNode.Object := MBDesc;

ObjNode.ReferenceConstraintsHandling := UpdateDataConstraintsHandlingType.Ask;

MUpdate.SaveToFileNF("c:\NSIDictionary.pefx");

End Sub Main;

After executing this example a new update is created. The MDM dictionary Dict_1 is included in this update. In case there are links to the elements, that are not present in the update, of the consumer dictionary in other dictionaries, then when the dictionary elements are updated the dialog with the selection of further operations is displayed.

See also:

IMetabaseUpdateDataObjectNode