Project

General

Profile

Actions

Bug #54952

closed

Update Wizard - DB Error

Added by Thomas Skierlo over 10 years ago. Updated over 10 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Install Tool
Target version:
-
Start date:
2014-01-13
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
6.2
PHP Version:
5.3
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

On latest HEAD from today I get an DB-Error directly after hitting "Update Wizard":

exec_SELECTquery
caller     TYPO3\CMS\Core\Database\DatabaseConnection::exec_SELECTquery
ERROR     Illegal mix of collations (utf8_general_ci,IMPLICIT) and (utf8_unicode_ci,IMPLICIT) for operation '<>'
lastBuiltQuery     SELECT COUNT(uid) FROM tt_content WHERE media <> '' AND CAST(CAST(media AS DECIMAL) AS CHAR) <> media OR (CType = 'uploads' AND select_key != '')
debug_backtrace     TYPO3\CMS\Install\Controller\ToolController->execute#134 // TYPO3\CMS\Install\Controller\ToolController->dispatchAuthenticationActions#74 // TYPO3\CMS\Install\Controller\Action\Tool\UpdateWizard->handle#176 // TYPO3\CMS\Install\Controller\Action\Tool\UpdateWizard->listUpdates#58 // TYPO3\CMS\Install\Updates\AbstractUpdate->shouldRenderWizard#83 // TYPO3\CMS\Install\Updates\TtContentUploadsUpdateWizard->checkForUpdate#127 // TYPO3\CMS\Core\Database\DatabaseConnection->exec_SELECTcountRows#105 // TYPO3\CMS\Core\Database\DatabaseConnection->exec_SELECTquery#426 // TYPO3\CMS\Core\Database\DatabaseConnection->debug#297

This sounds odd, since I'm using the following in my.cnf:

character_set_server=utf8
collation-server = utf8_unicode_ci
init-connect='SET NAMES utf8'
init_connect='SET collation_connection = utf8_unicode_ci'
skip-character-set-client-handshake

Manually checked the db, no occurrances of "utf8_general_ci". All "Datebase Checks" show green, same with Extension Checks. FE and BE are otherwise working.


Related issues 1 (0 open1 closed)

Is duplicate of TYPO3 Core - Bug #36754: SQL warning about collation in the install tool, Upgrade wizardClosed2012-05-01

Actions
Actions #1

Updated by Thomas Skierlo over 10 years ago

In /typo3/sysext/install/Classes/Updates/TtContentUploadsUpdateWizard.php

        public function checkForUpdate(&$description) {
                $updateNeeded = FALSE;
                // Fetch records where the field media does not contain a plain integer value
                // * check whether media field is not empty
                // * then check whether media field does not contain a reference count (= not integer)
                $notMigratedRowsCount = $GLOBALS['TYPO3_DB']->exec_SELECTcountRows(
                        'uid',
                        'tt_content',
                        'media <> \'\' AND CAST(CAST(media AS DECIMAL) AS CHAR) <> media OR (CType = \'uploads\' AND select_key != \'\')'
                );
                if ($notMigratedRowsCount > 0) {
                        $description = 'There are Content Elements of type "upload" which are referencing files that are not using ' . ' the File Abstraction Layer. Th$
                        $updateNeeded = TRUE;
                }
                return $updateNeeded;
        }

I'm no MySQL guru, but I'm quite sure that the (double) CAST is the reason for this error, which is no new one (see #36754)

Actions #2

Updated by Alexander Opitz over 10 years ago

  • Status changed from New to Closed

Close this issue as duplicate of #36754

Actions

Also available in: Atom PDF