on 04-10-2009 8:54 AM
Hi Friends,
I have scenraio in my application where we have a qualifier table " Sampleode".
when i add a new data it creates qualified link and add the entry like" ABC" . but i have a extend scenrio where i can extend the existing record in main table to new " sample code" for example "EFD". but at the time of save new qualifire " EFD" is over ridding all the qualified links availblea in " samplecode" qualifier table instead of adding a new entry over there.
It is causing a problem in our application and let me provide your valuable pointers.
Regards
Dushyant
Hi,
You can refer
Regards
Nisha
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
If you are facing problem in APIs... Use below sample code for adding qualified link to qualified table in cretae, Update,Extend opearations
int linkIndex = -1;
RecordId recordId = new RecordId("R1");
if(Change case){
linkIndex = this.existLink(qlv, recordId);
if(linkIndex == -1){
linkIndex = qlv.createQualifiedLink(recordId);
}
}else{ /* Create and Extend Case */
int numLinks = qlv.getValuesCount();
if (numLinks > 0) {
linkIndex = this.existLink(qlv, recordId);
if (linkIndex == -1) {
linkIndex = qlv.createQualifiedLink(recordId);
}
} else {
linkIndex = qlv.createQualifiedLink(recordId);
}
}
qlv.setQualifierFieldValue(linkIndex,
"Field ID ","Field Value");
//exist link method.
public int existLink(QualifiedLookupValue qlv, RecordId recordId) {
int linkIndex = -1;
boolean noEnd = true;
int index = 0;
int numLinks = qlv.getValuesCount();
while ((noEnd) && (index < numLinks)) {
if (qlv.getLookupId(index).getIdValue() == recordId.getIdValue()) {
noEnd = false;
linkIndex = index;
}
index++;
}
return linkIndex;
}
Thanks,
Veeru.
Hi Dushyant,
For handling Qualified links, there are an option given in the IMport Manager Configuration Options as
Default Qualified Update : The default setting for whether incoming source subrecords either are appended to, completely replace, or update the set of existing qualified links of a qualified lookup field when updating existing records:
There are 3 options there
1) Append
2) Replace
3) Update
I think, in your case, your configuration option should be set as Append or Update. This would add/update the Qualified links to the already existing ones.
Also refer the Import Manager Config Options :
http://help.sap.com/saphelp_mdm550/helpdata/en/43/12036df94c3e92e10000000a1553f6/frameset.htm
Go to-> Import Workflow->Config Options.
This would give you an idea.
Please try and check if it matches your requirement.
Thanks and Regards
Nitin Jain
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.