Actions
Bug #87593
closedInstall Tool > Wizard > Update sys_language records to use the newly sorting column
Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Install Tool
Target version:
-
Start date:
2019-01-31
Due date:
% Done:
100%
Estimated time:
TYPO3 Version:
9
PHP Version:
7.2
Tags:
Complexity:
easy
Is Regression:
Sprint Focus:
Description
Hi all,
the Upgrade Wizard "Update sys_language records to use the newly sorting column" is iterating over the entries at table "sys_language". In our case there are 27 entries in that table.
Here is the code fragment from executeUpdate function :
$sortCounter = 128; while ($languageRecord = $statement->fetch()) { // your code goes here $sortCounter *= 2; }
$sortCounter is to large for an INT (11) in the Database in our case. Which result in following error message:
Doctrine\DBAL\Exception\DriverException An exception occurred while executing ‘UPDATE `sys_language` SET `sorting` = ? WHERE `uid` = ?’ with params [2147483648, 14]: Out of range value for column ‘sorting’ at row 1
When i initialize $sortCounter with a lower value, fx:
$sortCounter = 2;
all went fine.
Little Test Code to show the Value:
<?php $x = 128; for ($i = 1; $i <= 28; $i++) { $x *= 2; }; var_dump($x); // Result => 34359738368
Best,
Michael
Updated by Gerrit Code Review almost 6 years ago
- Status changed from New to Under Review
Patch set 1 for branch 9.5 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/59772
Updated by Markus Klein almost 6 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset a527e83bd8f72568c10d3152438ca73df7665ba7.
Actions