cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - You can Bookmark boards, posts or articles that you'd like to access again easily! X

Failed to update data table (some times), getting - Data store unknown error

nmohammed
11-Garnet

Failed to update data table (some times), getting - Data store unknown error

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. 

 

nmohammed_0-1596181065981.png

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 .

1 ACCEPTED SOLUTION

Accepted Solutions

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.

View solution in original post

3 REPLIES 3
slangley
23-Emerald II
(To:nmohammed)

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.

slangley
23-Emerald II
(To:slangley)

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

Top Tags