Closed sindhumogare closed 7 months ago
Hello @sindhumogare ,
Thanks for reaching out and creating this issue. Regarding Request your urgent help on this issue.
, as this is an open-source project, immediate support can be challenging to provide. However, I do offer paid consulting services for urgent assistance. If interested, please contact me directly to discuss rates and details.
Meanwhile, please ensure your issue report includes all necessary information to facilitate quicker community support. Are you using a on-premise system and with which version?
@marianfoo I also wanted to create an issue concerning this topic. When an OData request fails because of an exception in the backend (RAP validation, BUSI_EXCEPTION etc) the changes are still pending in the model. Maybe you could add something like this somewhere after the request has been sent and response has been received (should work for both v2 and v4)?
if (oModel.hasPendingChanges()) {
oModel.resetChanges();
}
I guess in this case it leads to all the entities being uploaded twice (the old pending changes and the re-up) thus generating the non unique key error.
I guess in this case it leads to all the entities being uploaded twice (the old pending changes and the re-up) thus generating the non unique key error.
I also suspect that it has something to do with that. I have a lot to do at the moment so I don't know when I'll get around to it.
@sindhumogare @marianfoo quick workaround cold be adding a handler for requestCompleted
(see https://docs.spreadsheet-importer.com/pages/Events/#event-when-the-request-is-completed) where one could do
const oModel = this.getView().getModel();
if (oModel.hasPendingChanges()) {
oModel.resetChanges();
}
Hi @sindhumogare and @MARCxGAMBIT sorry for the long wait. Can you please check if this would fix it in #525 :
fix was release with version 0.33.3
, please check if that helped
OData Version
OData V2
Draft
Yes
Scenario
Fiori Elements
Environment
BAS
UI5 Spreadsheet Component
cc.spreadsheetimporter.v0_32_0
What happened?
I am using this component to upload my data which is in a spreadsheet from my presentation server. According to the logic required, when I upload the data, I validate it in the backend RAP Application. On receiving error in the backend for the first time, the spreadsheet component is giving the correct error. When I correct the data in the spreadsheet and try to re-upload the excel spreadsheet through the component, it throws the error: "The key value is already in use. Please enter a different one."
Request your urgent help on this issue.
Best Regards, Sindhu Mogare
Relevant log output
Spreadsheet Component Init
Manifest