Community Tip - Want the oppurtunity to discuss enhancements to PTC products? Join a working group! X
Hi
We are trying to update data table during run time and we are encountering the following exception some times. We observed like after 3 or 4 continuous operations we are getting this error.
java.util.concurrent.ExecutionException: java.lang.RuntimeException: com.thingworx.common.exceptions.DataAccessException: [1,018] Data store unknown error: [Error occurred while accessing the data provider.]
The following is the data table structure snippet, we have 2 string columns as primary key and the max number of records are less than 50 in this data table.
The following is the service we are using to update the data table.
var params = {
tags : tags,
source : me.name,
values : values,
location : location
};
// AddOrUpdateDataTableEntry(tags:TAGS, source:STRING("me.name"), values:INFOTABLE(IIOT_EN_DT_ResponsiblePerson), location:LOCATION):STRING
var id = Things["IIOT_EN_DT_ResponsiblePerson"].AddOrUpdateDataTableEntry(params);
It is a show stopper for us now. Highly appreciate if you have any recommendations .
Solved! Go to Solution.
During our investigation we found that update data table service being called twice at the same time, one from mashup and one from another service. The script error log was throwing duplicate key for both the service attempts instead of inserting a record for one service and throwing duplicate for another service attempt.
We removed service binding from the mashup. Issue got resolved.
We can close this thread.
Hi @nmohammed.
I would recommend checking the knowledge base for potential causes. This might be a good starting point.
If you're unable to make any progress toward a solution, I recommend that a case be opened. I will be happy to open one on your behalf.
Regards.
--Sharon
During our investigation we found that update data table service being called twice at the same time, one from mashup and one from another service. The script error log was throwing duplicate key for both the service attempts instead of inserting a record for one service and throwing duplicate for another service attempt.
We removed service binding from the mashup. Issue got resolved.
We can close this thread.
Hi @nmohammed.
I'm glad to hear you have resolved your issue. For the benefit of others on the community, please mark your last post as the Accepted Solution.
Thank you for following up to provide the solution.
Regards.
--Sharon