We have a requirement to import the data from one entity to another within the same environment. We are trying to use ForAll with a Patch statement as follows.
//Inside ForAll -> Patch Statement code
Status: If(
CollectionCreatedOutOfSourceTable.Status = 'Status (SourceTable)'.Open,
'Status (TargetTable)'.Open,
'Status (TargetTable)'.Closed
)
We do not see any syntax error with the above piece of code. However, we are getting the following runtime error.
statecode: the specified column is generated by server and cannot be specified
We are getting various errors such as expecting an option set value or default schema has been changed when we try to modify the code. FYI, the Status column has the same data type and the same set of choices such as Open/Closed in both the source and target tables
If we remove the Status column from the patch statement then it just seems to work fine.
FYI, we do not have any issues patching the default status column inside the target table in the new app.
Thank you!!