cancel
Showing results for 
Search instead for 
Did you mean: 

SetPropertyComparable - available parameters

former_member217396
Participant
0 Kudos

Hi all,

We are trying to use the Comparison Helper to compare two LDM models and extract the changes into an Excel file. This works fine, but now we would like to exclude an extended attribute (metaclass Entity Attribute) from the comparison. For this we use the method SetPropertyComparable, but we cannot find the correct syntax for this, hence, what to use as ClssName and PropName.

We have two models, mdl1 and mdl2 and would like the exclude the extended attribute "Catalogue" from the comparison. We tried many things, but it doesn't seem to work:

Set Cmpr = mdl1.CreateComparisonHelper(mdl2)
Cmpr.SetClassComparable "*", TRUE
Cmpr.SetPropertyComparable "EntityAttribute", "ExtendedAttributes.Catalogue", FALSE

For id = 0 To Cmpr.GetDifferencesCount()
Cmpr.GetDifferenceInformation id, DiffKind, OldObject, NewObject, MemberPublicName, OldValue, NewValue
If DiffKind = mrg_modified Then
output "Old:" OldObject + ", new:" + NewObject
End If
Next

Could someone please tell us what the correct syntax is to do this?

BR,

Rafal

Accepted Solutions (0)

Answers (2)

Answers (2)

former_member217396
Participant
0 Kudos

Thanks for your answer. I don't understand exactly what you mean. The arguments SetPropertyComparable have to be public names. For entity attributes this is EntityAttribute. We have tried also using the class name, like cls_xxx but this doesn't seem to work.

We believe the first argument (describing the class name) should be ok, since it works if we write for instance SetPropertyComparable "EntityAttirbute", "DataType", False. We are, however, in doubt about the second argument, since this is not a standard property of the metaclass, but an extended attribute. We are not sure how to address this extended attribute in the extension. An entity attribute hast the property ClassPublicName, but this property is not available for extended attributes. It is also possible to have more than one extension with the same extended attribute, so perhaps we also need the extension name in the argument. However, you can get the extended attribute value directly from the attribute by using GetExtendedAttribute, so perhaps you don't need to "navigate" through the extension.

GeorgeMcGeachie
Active Contributor
0 Kudos

Have you tried qualifying "ExtendedAttributes.Catalogue" with the Library and Class Name?