Hi Expert,
need your help on below scenario.
Scenario: A document with two categories (Cat A and Cat
are already applied.
we need to update a field value of category A only untouching Category B.
Below code snipet works fine to update the category A value, but some how its removing/deleting other category B entirely from document.. At the end of the script the document remains with Category A with updated value and all data with along with category get removed.
Pls suggest how to handle this situation. I tried using both method docManClient.updateNode(docNode) and docManClient.setNodeMetadata(320044, metadata1);,but the result is the same.
---------------------------------------------------------------------------------------------------------------------------
Node docNode = docManClient.getNode(320044);
StringValue fnametest = (StringValue) categoryTemplate1.getValues().get(0);
fnametest.getValues().clear();
fnametest.getValues().add("samtesting");
Metadata metadata1 = new Metadata();
metadata1.getAttributeGroups().add(categoryTemplate1);
try
{
docNode.setMetadata(metadata1);
docManClient.updateNode(docNode);// (nodeID, metadata);//.setNodeMetadata(320044, metadata1);
}
catch (SOAPFaultException e)
Thanks
Sambit