Hi. I'm having a problem upgrading our EspoCRM to latest version from 5.9.4. Logs are showing a rebuild problem related to an ALTER TABLE MySQL command:
I've managed to ran the ALTER TABLE script available in the forum but again the error seems to be coming from the upgrade process.
Any hint please?
Rgds
Nuno
Code:
[FONT=Courier New]Espo.ALERT: Rebuild database fault: PDOException: SQLSTATE[HY000]: General error: 1366 Incorrect integer value : ' ' for column 'id' at row 1 in /var/www/espocrm/vendor/doctrine/dbal/lib/Doctrine/DBAL/Connection.php:699 Stack trace: #0 /var/ww w/espocrm/vendor/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(699): PDO->query('ALTER TABLE `ac...') #1 /var/www/espocrm/applicati on/Espo/Core/Utils/Database/Schema/Schema.php(228): Doctrine\DBAL\Connection->executeQuery('ALTER TABLE `ac...') #2 /var/www/espocrm /application/Espo/Core/Utils/Database/Schema/SchemaProxy.php(53): Espo\Core\Utils\Database\Schema\Schema->rebuild() #3 /var/www/espo crm/application/Espo/Core/DataManager.php(122): Espo\Core\Utils\Database\Schema\SchemaProxy->rebuild(NULL) #4 /var/www/espocrm/appli cation/Espo/Core/DataManager.php(93): Espo\Core\DataManager->rebuildDatabase(NULL) #5 /var/www/espocrm/application/Espo/Core/Upgrade s/Actions/Base.php(737): Espo\Core\DataManager->rebuild() #6 /var/www/espocrm/application/Espo/Core/Upgrades/Actions/Base.php(170): Espo\Core\Upgrades\Actions\Base->systemRebuild() #7 /var/www/espocrm/application/Espo/Core/Upgrades/Actions/Base/Install.php(276): Espo\Core\Upgrades\Actions\Base->throwErrorAndRemovePackage('Error occurred ...', true, true) #8 /var/www/espocrm/application/Espo/Core/Upgrades/Actions/Base/Install.php(180): Espo\Core\Upgrades\Actions\Base\Install->throwErrorAndRemovePackage('Error occurred ...') #9 /var/www/espocrm/application/Espo/Core/Upgrades/Base.php(130): Espo\Core\Upgrades\Actions\Base\Install->stepRebuild(Array) #10 /var/www/espocrm/application/Espo/Core/Upgrades/Base.php(113): Espo\Core\Upgrades\Base->runActionStep('install', 'Rebuild', Array) #11 /var/www/espocrm/application/Espo/Core/Console/Commands/UpgradeStep.php(74): Espo\Core\Upgrades\Base->runInstallStep('Rebuild', Array) #12 /var/www/espocrm/application/Espo/Core/Console/Commands/UpgradeStep.php(63): Espo\Core\Console\Commands\UpgradeStep->runUpgradeStep('Rebuild', Array) #13 /var/www/espocrm/application/Espo/Core/Console/CommandManager.php(78): Espo\Core\Console\Commands\UpgradeStep->run(Array, Array, Array) #14 /var/www/espocrm/application/Espo/Core/ApplicationRunners/Command.php(56): Espo\Core\Console\CommandManager->run(Array) #15 /var/www/espocrm/application/Espo/Core/Application.php(107): Espo\Core\ApplicationRunners\Command->run(NULL) #16 /var/www/espocrm/command.php(39): Espo\Core\Application->run('Espo\\Core\\Appli...') #17 {main} Next Doctrine\DBAL\DBALException: An exception occurred while executing 'ALTER TABLE `account` CHANGE `id` `id` INT AUTO_INCREMENT NOT NULL COLLATE utf8mb4_unicode_ci': SQLSTATE[HY000]: General error: 1366 Incorrect integer value: ' ' for column 'id' at row 1 in /var/www/espocrm/vendor/doctrine/dbal/lib/Doctrine/DBAL/DBALException.php:91 Stack trace: #0 /var/www/espocrm/vendor/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(702): Doctrine\DBAL\DBALException::driverExceptionDuring Query(Object(PDOException), 'ALTER TABLE `ac...', Array) #1 /var/www/espocrm/application/Espo/Core/Utils/Database/Schema/Schema.php(228): Doctrine\DBAL\Connection->executeQuery('ALTER TABLE `ac...') #2 /var/www/espocrm/application/Espo/Core/Utils/Database/Schema/SchemaProxy.php(53): Espo\Core\Utils\Database\Schema\Schema->rebuild() #3 /var/www/espocrm/application/Espo/Core/DataManager.php(122): Espo\Core\Utils\Database\Schema\SchemaProxy->rebuild(NULL) #4 /var/www/espocrm/application/Espo/Core/DataManager.php(93): Espo\Core\DataManager->rebuildDatabase(NULL) #5 /var/www/espocrm/applicatio[/FONT]
Any hint please?
Rgds
Nuno
Comment