Database error when updating

Hi

I have been trying to update to the latest version of Mautic for some time- but ran into some problems. Today I gave it a new try - and after trying different things - I see this error message in the logs:

console.CRITICAL: Error thrown while running command "'doctrine:migration:migrate'". Message: "An exception occurred while executing a query: SQLSTATE[23000]: Integrity constraint violation: 4025 CONSTRAINT `sms_message_stats.details` failed for `xxxx_mautic`.`sms_message_stats`" {"exception":"[object] (Doctrine\\DBAL\\Exception\\DriverException(code: 4025): An exception occurred while executing a query: SQLSTATE[23000]: Integrity constraint violation: 4025 CONSTRAINT `sms_message_stats.details` failed for `xxxx_mautic`.`sms_message_stats` at /var/www/vhosts/xxxxxx/xxxxx/vendor/doctrine/dbal/src/Driver/API/MySQL/ExceptionConverter.php:117)\n[previous exception] [object] (Doctrine\\DBAL\\Driver\\PDO\\Exception(code: 4025): SQLSTATE[23000]: Integrity constraint violation: 4025 CONSTRAINT `sms_message_stats.details` failed for `xxxxxx_mautic`.`sms_message_stats` at /var/www/vhosts/xxxxxxx/xxxxxx/vendor/doctrine/dbal/src/Driver/PDO/Exception.php:28)\n[previous exception] [object] (PDOException(code: 23000): SQLSTATE[23000]: Integrity constraint violation: 4025 CONSTRAINT `sms_message_stats.details` failed for `xxxxx_mautic`.`sms_message_stats` at /var/www/vhosts/xxxxx/xxxxxx/vendor/doctrine/dbal/src/Driver/PDO/Connection.php:71)","command":"'doctrine:migration:migrate'","message":"An exception occurred while executing a query: SQLSTATE[23000]: Integrity constraint violation: 4025 CONSTRAINT `sms_message_stats.details` failed for `xxx_mautic`.`sms_message_stats`"}

Any one who knows how to fix it? It was an upgrade from version 4x to 5