fields icon indicating copy to clipboard operation
fields copied to clipboard

Error update GLPI 9.4.4 and Plugin 1.10.2 to 9.5.5 and 1.12.6

Open phamorais opened this issue 3 years ago • 4 comments

Hey guys!

I'm trying to update the plugin in CLI and WEB, but I get the error below.

image

Instalação de tabelas no MySQL
DBmysql::query() in /usr/share/nginx/html/pasc/inc/dbmysql.class.php line 309 *** MySQL query error: SQL: CREATE TABLE IF NOT EXISTS `glpi_plugin_fields_fournineseventwozeroseventhreetwofielddropdowns` ( `id` INT(11) NOT NULL auto_increment, `name` VARCHAR(255) DEFAULT NULL, `completename` TEXT DEFAULT NULL, `comment` TEXT DEFAULT NULL, `plugin_fields_fournineseventwozeroseventhreetwofielddropdowns_id` INT(11) DEFAULT NULL, `level` INT(11) DEFAULT NULL, `ancestors_cache` TEXT DEFAULT NULL, `sons_cache` TEXT DEFAULT NULL, `entities_id` INT(11) NOT NULL DEFAULT '0', `is_recursive` TINYINT(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`), KEY `entities_id` (`entities_id`), KEY `is_recursive` (`is_recursive`), KEY `plugin_fields_fournineseventwozeroseventhreetwofielddropdowns_id` (`plugin_fields_fournineseventwozeroseventhreetwofielddropdowns_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; Error: Incorrect table name 'glpi_plugin_fields_fournineseventwozeroseventhreetwofielddropdowns' Backtrace : ...ntwozeroseventhreetwofielddropdown.class.php:41 plugins/fields/inc/dropdown.class.php:140 PluginFieldsFournineseventwozeroseventhreetwofieldDropdown::install() plugins/fields/inc/dropdown.class.php:45 PluginFieldsDropdown::create() plugins/fields/hook.php:80 PluginFieldsDropdown::install() inc/plugin.class.php:726 plugin_fields_install() inc/console/plugin/installcommand.class.php:134 Plugin->install() vendor/symfony/console/Command/Command.php:255 Glpi\Console\Plugin\InstallCommand->execute() vendor/symfony/console/Application.php:1000 Symfony\Component\Console\Command\Command->run() inc/console/application.class.php:249 Symfony\Component\Console\Application->doRunCommand() vendor/symfony/console/Application.php:271 Glpi\Console\Application->doRunCommand() vendor/symfony/console/Application.php:147 Symfony\Component\Console\Application->doRun() bin/console:102 Symfony\Component\Console\Application->run() SQL Error "1103": Incorrect table name 'glpi_plugin_fields_fournineseventwozeroseventhreetwofielddropdowns' in query "CREATE TABLE IF NOT EXISTS `glpi_plugin_fields_fournineseventwozeroseventhreetwofielddropdowns` ( `id` INT(11) NOT NULL auto_increment, `name` VARCHAR(255) DEFAULT NULL, `completename` TEXT DEFAULT NULL, `comment` TEXT DEFAULT NULL, `plugin_fields_fournineseventwozeroseventhreetwofielddropdowns_id` INT(11) DEFAULT NULL, `level` INT(11) DEFAULT NULL, `ancestors_cache` TEXT DEFAULT NULL, `sons_cache` TEXT DEFAULT NULL, `entities_id` INT(11) NOT NULL DEFAULT '0', `is_recursive` TINYINT(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`), KEY `entities_id` (`entities_id`), KEY `is_recursive` (`is_recursive`), KEY `plugin_fields_fournineseventwozeroseventhreetwofielddropdowns_id` (`plugin_fields_fournineseventwozeroseventhreetwofielddropdowns_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;" Incorrect table name 'glpi_plugin_fields_fournineseventwozeroseventhreetwofielddropdowns'

image

image

Can help us?

phamorais avatar Jul 27 '21 21:07 phamorais

Any?

phamorais avatar Jul 30 '21 17:07 phamorais

@stonebuzz can u help us?

phamorais avatar Aug 03 '21 14:08 phamorais

Guys posting just to help in case anyone catches the same mistake.

In a joint analysis with @tomolimo , we identified that in our base we have a field without a linked container, as shown in the image below

image

I cannot explain how this happened. But @tomolimo solution was to delete the faulty record, and after that I was able to update without problems.

image

image

phamorais avatar Aug 04 '21 15:08 phamorais

As shown, it was linked to a field with too long field name...

tomolimo avatar Aug 23 '21 09:08 tomolimo