on 03-15-2010 5:54 PM
Hi all,
I am getting the following error while trying to modify a record via MDM 7.1 Java API.
modifyRecord:Failed record while modifying:com.sap.mdm.internal.protocol.manual.ServerException: The requested record was not found
com.sap.mdm.commands.CommandException: com.sap.mdm.internal.protocol.manual.ServerException: The requested record was not found
at com.sap.mdm.data.commands.ModifyRecordCommand.execute(ModifyRecordCommand.java:210)
at com.alu.mdm.products.ProductsUpload.modifyRecord(ProductsUpload.java:1720)
at com.alu.mdm.products.ProductsUpload.readExcelandCreateRecords(ProductsUpload.java:533)
at com.alu.mdm.products.TestProductsUpload.main(TestProductsUpload.java:147)
Caused by: com.sap.mdm.internal.protocol.manual.ServerException: The requested record was not found
at com.sap.mdm.internal.protocol.manual.AbstractProtocolCommand.execute(AbstractProtocolCommand.java:126)
at com.sap.mdm.data.commands.ModifyRecordCommand.execute(ModifyRecordCommand.java:170)
Can someone give a clue on what could be the possible causes?
Below is the code:
modifyRecordCommand = new ModifyRecordCommand(userctx);
modifyRecordCommand.setSession( usrSessionIdAdm );
modifyRecordCommand.setRecord(recModify);
modifyRecordCommand.setModifyAnyway(true);
modifyRecordCommand.setCommitOnWarning(true);
modifyRecordCommand.execute();
I have checked the data in the record and it looks fine.
HI,
Can you share a solution of the same.
Regards,
Sunil
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Sunil,
I don´t know if you solved this issue, but I´ll share you my soultion:
I was getting the Exception because I was using a MdmValue extracted from the record (It was a MultiTupleValue). So for the solution, I recreate the MultiTupleValue, (yeah: ... new MultiTupleValue() ) and loop the original MultiTupleValue and setting the new.
Regards!
Hi,
I am using ModifyRecordCommand for modyfing record.After executing command no exception is thrown,but record is not getting modifyied.
I can use ModifyRecordsCommand,but it does not have setModifyAnyway() option.But I need setModifyAnyway(true) option.
Please help on this issue.
Thanks,
Anuja
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
I am not gettimg exceptions (CommandException) while running ModifyRecordsCommand,but when I check MultipleRecordResult as follows,
MultipleRecordsResult multipleRecordsResult=commandd.getResult();
multipleRecordsResult.getFailedRecordMessage();
I will get message "Could not modify record".
There is no other exception thrown.What could be the reason for failing this modification operation?Is it related to ChangeStamp?
Please help on this issue.
Thanks,
Anuja
Dear bipsrane,
I hope you are using same session context (i.e. session context for same user) for both fetching and then modifying.
Please confirm.
-- Shaailesh.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Where does recModify come from? Can you show that code?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
86 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.