When trying to update service plan or install APS application, the following error message appears:
Violation of PRIMARY KEY constraint 'longtaskparamsPrimaryKey', cannot insert duplicate key in object 'dbo.longtaskparams'. The duplicate key value is ('id', 'name').
longtasks' was cleaned, but table '
longtaskparams' was not and contains old orphan records. As a result Plesk tries to use duplicated ID values.
You should always clean both tables:
longtasks if it is needed for some reasons.
To fix the issue clean up '
longtaskparams' table with the command:
"%plesk_bin%\dbclient" --direct-sql --sql="truncate table longtaskparams"