Is there any way to upgrade an extension, with “schema breaking Changes” (PK changed for one table) and restore the user data for the extension tables?
I have searched and found some threads for this issue, but I am still a bit confused. Some threads states that this is not possible and yet some suggests to solve this using an upgrade codeunit. I have made a number of tries, but have not yet succeeded. As far as I understand the procedure is to (uninstall the old version), publish, sync and DataUpgrade the new extension version, while the DataUpgrade automatically should detect and run the upgrade codeunit.
When performing this procedure the Sync fails with an error message related to the schema breaking change and the only remaining option seems to be a sync in “-Clean” mode. The following DataUpgrade command then fails with an error message that no prior extension version can be found.
Thanks in advance