Saving a form with a change of status field caused an empty concurrency exception

I was trying to save a form with a changed state-aware field. It caused to run a state-transition workflow that loaded the entity data, transform it (without anything changed) and saved it.

I was expecting everything to go smoothly without errors.

Instead I’ve got a totally empty DB concurrency exception (without telling what went wrong).

We spotted and fixed several problems:

  1. We found out the problem was caused by the fact, that some fields were empty strings in the database. Once loaded and transformed, they changed to ‘null’ values (this is a consequence of deleting empty attributes and elements after transformation). The change emptystring->null triggered also ‘RecordUpdated’ to be changed and the record was updated and saved to the db. Then, the original update took a place and it then obviously triggered concurrency exception. Nevertheless, the concurrency exception didn’t show any changed values.

  2. We found out, the exception message string was empty because composing a diagnostics message was done after a rollback of a workflow-performed update and therefore it couldn’t load original values.

  3. Finally, we found out a data structure lookup column causes a record to be marked as updated, even thought it was from a different entity (and moreover, it was actually not changed, only idle emptystring->null transition was performed). So we managed the dataset generator doesn’t mark the column as the database mapped entity field, so that the merge approach the column in the similar way as other non-database fields.

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.