Bug #68418

Epic #68397: Make TYPO3 work with MySQL strict mode

scheduler chokes on mysql strict mode

Added by Anja Leichsenring 14 days ago. Updated 6 days ago.

Status:Resolved Start date:2015-07-21
Priority:Should have Due date:
Assigned To:Morton Jonuschat % Done:

100%

Category:Database API Spent time: -
Target version:7 LTS
TYPO3 Version:7 Is Regression:No
PHP Version:5.5 Sprint Focus:
Complexity:

Description

I run mysql Ver 14.14 Distrib 5.5.43, for debian-linux-gnu (x86_64) using readline 6.3, which contains the Strict mode handling introduced with mysql 5.6. So I run strict mode.

The scheduler gives error messages upon creating or updating scheduler tasks, containing messages like

caller => "TYPO3\CMS\Core\Database\DatabaseConnection::exec_INSERTquery" (60 chars)
ERROR => "Field 'lastexecution_failure' doesn't have a default value" (58 chars)

or

caller => "TYPO3\CMS\Core\Database\DatabaseConnection::exec_UPDATEquery" (60 chars)
ERROR => "Incorrect integer value: '' for column 'disable' at row 1" (57 chars)

and even Exceptions.

By adjusting my my.cnf file, commenting out the line STRICT_ALL_TABLES and restarting mysql, I got it to work.


Related issues

related to Core - Bug #68562: Bool values need to be cast to integer for MySQL strict mode New 2015-07-27

Associated revisions

Revision f1355b35
Added by Morton Jonuschat 6 days ago

[BUGFIX] Scheduler: make lastexecution_failure field non-mandatory

MySQL in strict mode requires TEXT fields defined with the NOT NULL
attribute to be explicitly set on INSERT statements. Due to execution
failures of scheduler jobs being the exception and not the rule as well
as MySQL not allowing DEFAULT values for TEXT colums changing the field
to not be mandatory is sensible.

Resolves: #68418
Releases: master
Change-Id: I0ed3a3b70d4f61f8e418741ae76aa0010b6c68a3
Reviewed-on: http://review.typo3.org/41994
Reviewed-by: Wouter Wolters <>
Tested-by: Wouter Wolters <>
Reviewed-by: Daniel Goerz <>
Reviewed-by: Tomas Norre Mikkelsen <>
Tested-by: Tomas Norre Mikkelsen <>
Reviewed-by: Stefan Neufeind <>
Tested-by: Stefan Neufeind <>

History

#1 Updated by Morton Jonuschat 13 days ago

  • Category changed from DBAL to Database API
  • Assigned To set to Morton Jonuschat
  • Target version set to 7 LTS

#2 Updated by Gerrit Code Review 7 days ago

  • Status changed from New to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/41994

#3 Updated by Morton Jonuschat 6 days ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100

Also available in: Atom PDF