Hi guys,
I have a qualified lookup field in main table, and one qualifier field has multi-lingual set to true. Now i'm able to save normal string value to qualifier field, but when I tried to save multi-lingual value I got below error:
java.lang.IllegalArgumentException: Field with ID 'F199_823' either is not qualifier field or belongs to another table
at com.sap.mdm.internal.valuetypes.QualifiedLinkValueImpl.getQualifierValue(QualifiedLinkValueImpl.java:170)
at com.sap.mdm.valuetypes.QualifiedLookupValue.getMultiregionQualifierFieldValue(QualifiedLookupValue.java:147)
The code I used:
QualifiedLookupValue qualifiedLookupValue = new QualifiedLookupValue();
int index = qualifiedLookupValue.createQualifiedLink(recordLookup); // recordLookup is the record in qualifier lookup table
MultiregionValue multiRegionValue = qualifiedLookupValue.getMultiregionQualifierFieldValue(index, fldQualifier); // fldQualifier is the qualifier field in qualified lookup table
multiRegionCharValue.setValue("engUSA", new StringValue("qualifier value - EN"));
qualifiedLookupValue.setQualifierFieldValue(index, fldQualifier, multiRegionValue);
recordMain.setFieldValue(fldQFT, qualifiedLookupValue); // recordMain is the record in main table that I want to set multi-lingual qualifier value; fldQFT it the qualifier lookup field in main table
Anyone knows if the getMultiregionQualifierFieldValue() API should be used like this?
Thanks,
James