IRdsNotConvertibleReasonIncorrectStructure.ExcessedTranslationAttributes

Syntax

ExcessedTranslationAttributes: Array;

ExcessedTranslationAttributes: System.Array;

Description

The ExcessedTranslationAttributes property returns keys of excessive translation attributes.

Comments

To get keys of the links containing integrity inconsistency, use the IRdsNotConvertibleReasonIncorrectStructure.NullReferencedLinks property.

Fore Example

Executing the example requires an MDM repository with the 16008 key that contains MDM dictionaries required to convert to table MDM dictionaries.

Add links to the Metabase, Rds system assemblies.

Sub UserProc;
Var
    RDS_DB: IRdsDatabase;
    Converter: IRdsDictionaryConverter;
    List: IRdsDictionaryConverterList;
    NotConv: IMetabaseObjectDescriptors;
    pReasons: IRdsNotConvertibleReasons;
    pReason: IRdsNotConvertibleReason;
    ReasonIncorrStruct: IRdsNotConvertibleReasonIncorrectStructure;
    i, j, k: Integer;
Begin
    RDS_DB := MetabaseClass.Active.Bind(16008As IRdsDatabase;
    Converter := New RdsDictionaryConverter.Create;
    List := Converter.AllRdsDatabase(RDS_DB);
    NotConv := List.NotConvertibleDictionaries;
    For i := 0 To NotConv.Count - 1 Do
    pReasons := List.GetNotConvertibleReasons(NotConv.Item(i).Key);
        For j := 0 To pReasons.Count - 1 Do
            pReason := pReasons.Item(j);
            ReasonIncorrStruct := pReason As IRdsNotConvertibleReasonIncorrectStructure;
            Debug.Write("Keys of excessive translation attributes: ");
            For k := 0 To ReasonIncorrStruct.ExcessedTranslationAttributes.Length - 1 Do
                Debug.WriteLine(ReasonIncorrStruct.ExcessedTranslationAttributes[k]);
            End For;
            Debug.Write("Keys of links with integrity inconsistency: ");
            For k := 0 To ReasonIncorrStruct.NullReferencedLinks.Length - 1 Do
                Debug.WriteLine(ReasonIncorrStruct.NullReferencedLinks[k]);
            End For;
        End For;
    End For;
End Sub UserProc;

Imports Prognoz.Platform.Interop.Metabase;
Imports Prognoz.Platform.Interop.Rds;

Public Shared Sub Main(Params: StartParams);
Var
    RDS_DB: IRdsDatabase;
    Converter: IRdsDictionaryConverter;
    List: IRdsDictionaryConverterList;
    NotConv: IMetabaseObjectDescriptors;
    pReasons: IRdsNotConvertibleReasons;
    pReason: IRdsNotConvertibleReason;
    ReasonIncorrStruct: IRdsNotConvertibleReasonIncorrectStructure;
    i, j, k: Integer;
    ExcessedTranslAtt, NullRefLinks: System.Array;
Begin
    RDS_DB := Params.Metabase.Bind(16008As IRdsDatabase;
    Converter := New RdsDictionaryConverter.Create();
    List := Converter.AllRdsDatabase(RDS_DB);
    NotConv := List.NotConvertibleDictionaries;
    For i := 0 To NotConv.Count - 1 Do
    pReasons := List.GetNotConvertibleReasons(NotConv.Item[i].Key);
        For j := 0 To pReasons.Count - 1 Do
            pReason := pReasons.Item[j];
            ReasonIncorrStruct := pReason As IRdsNotConvertibleReasonIncorrectStructure;
            System.Diagnostics.Debug.Write("Keys of excessive translation attributes: ");
            For k := 0 To ReasonIncorrStruct.ExcessedTranslationAttributes.Length - 1 Do
                ExcessedTranslAtt := ReasonIncorrStruct.ExcessedTranslationAttributes;
                System.Diagnostics.Debug.WriteLine(ExcessedTranslAtt[k]);
            End For;
            System.Diagnostics.Debug.Write("Keys of links with integrity inconsistency: ");
            For k := 0 To ReasonIncorrStruct.NullReferencedLinks.Length - 1 Do
                NullRefLinks := ReasonIncorrStruct.NullReferencedLinks;
                System.Diagnostics.Debug.WriteLine(NullRefLinks[k]);
            End For;
        End For;
    End For;
End Sub;

After executing the example the console window displays keys of excessive translation attributes and keys of links with integrity inconsistency.

See also:

IRdsNotConvertibleReasonIncorrectStructure