I understand that the table's data method creates a copy of a record including the system fields. Normally it should generate a new RecID, which is reasonable because otherwise you cannot insert the record in the same table.
Now I'm having a case where the data method is creating a copy which has the same RecId, leading to an error during the insert operation. I'm not sure why this is happening and would appreciate any input on this topic.
What I'm doing:
- Duplicating an existing product configuration model
- When I run the debugger, at some point the execution thread reaches a table method PCClass.duplicateTranslation()
- In line 20 and 22 we can see that a duplicate record is created, which is then tried to insert, which fails because they have both the same RecId (see next screenshot)
This is a standard AX method, so why isn't it working?