Bug #67186
Epic #68397: Make TYPO3 work with MySQL strict mode
Impossible to save to tt_content
Status: | Resolved | Start date: | 2015-05-29 | |
---|---|---|---|---|
Priority: | Should have | Due date: | ||
Assigned To: | Morton Jonuschat | % Done: | 100% |
|
Category: | DBAL | Spent time: | - | |
Target version: | 8 | |||
TYPO3 Version: | 6.2 | Is Regression: | No | |
PHP Version: | Sprint Focus: | |||
Complexity: |
Description
There seems to be a flaw in the SQL definition for the tt_content table.
The current definition is filelink_sorting tinytext NOT NULL,
, however it should have a DEFAULT ''
clause.
This might only happen on SQL strict mode.
I did not actually reproduce it, but note it here so it does not get lost:
http://stackoverflow.com/questions/30484041/typo3-sorry-you-didnt-have-proper-permissions-to-perform-this-change/
Associated revisions
[BUGFIX] Provide default value for field tt_content.filelink_sorting
Changing the field type for filelink_sorting to a text type that supports
a default value allows inserts into tt_content to succeed when no sorting
option was provided, fixing problems with MySQL strict mode.
Resolves: #67186
Resolves: #52206
Releases: master
Change-Id: Ie9a06fff14ec62c9cbc8d15cc957f5fcbe698393
Reviewed-on: http://review.typo3.org/41756
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Reviewed-by: Daniel Goerz <ervaude@gmail.com>
Reviewed-by: Stefan Neufeind <typo3.neufeind@speedpartner.de>
Tested-by: Stefan Neufeind <typo3.neufeind@speedpartner.de>
History
#1 Updated by Markus Klein 2 months ago
Strict mode is not supported.
https://git.typo3.org/Packages/TYPO3.CMS.git/blob_plain/refs/heads/TYPO3_6-2:/INSTALL.md
#2 Updated by Morton Jonuschat about 1 month ago
MySQL BLOB and TEXT columns can not have default values: https://dev.mysql.com/doc/refman/5.6/en/blob.html
In that case it might make sense to replace tinytext with VARCHAR NOT NULL DEFAULT '', this should match how the field is being used according to TCA.
#3 Updated by Riccardo De Contardi 14 days ago
- Category set to DBAL
- Target version set to 8
#4 Updated by Mathias Schreiber 14 days ago
- Parent task set to #68397
#5 Updated by Morton Jonuschat 14 days ago
- Assigned To set to Morton Jonuschat
#6 Updated by Gerrit Code Review 14 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/41756
#7 Updated by Gerrit Code Review 14 days ago
Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/41756
#8 Updated by Morton Jonuschat 14 days ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset 87af9d6d7bfddc531d0a07541b0274d84cc07c11.