[BUGFIX] Allow signed integers in details_nr column of sys_log table 26/42626/2
authorMorton Jonuschat <m.jonuschat@mojocode.de>
Fri, 14 Aug 2015 12:36:22 +0000 (14:36 +0200)
committerMarkus Klein <markus.klein@typo3.org>
Sat, 15 Aug 2015 17:22:17 +0000 (19:22 +0200)
DataHandler->log() uses -1 as a default value for details_nr. This
conflicts with the SQL schema which defines the column as unsigned.
With MySQL strict mode this discrepancy leads to SQL errors. As there
is no reason not to use the -1 in the database change the SQL schema
to allow negative values.

Resolves: #69060
Releases: master
Change-Id: I6598e7aafb50034ca7df3b79cfa39fa669c21dd3
Reviewed-on: http://review.typo3.org/42626
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Tested-by: Wouter Wolters <typo3@wouterwolters.nl>
Reviewed-by: Daniel Goerz <ervaude@gmail.com>
Tested-by: Daniel Goerz <ervaude@gmail.com>
Reviewed-by: Markus Klein <markus.klein@typo3.org>
Tested-by: Markus Klein <markus.klein@typo3.org>
typo3/sysext/core/ext_tables.sql

index 5852652..3568420 100644 (file)
@@ -603,7 +603,7 @@ CREATE TABLE sys_log (
        details text NOT NULL,
        tstamp int(11) unsigned DEFAULT '0' NOT NULL,
        type tinyint(3) unsigned DEFAULT '0' NOT NULL,
-       details_nr tinyint(3) unsigned DEFAULT '0' NOT NULL,
+       details_nr tinyint(3) DEFAULT '0' NOT NULL,
        IP varchar(39) DEFAULT '' NOT NULL,
        log_data text,
        event_pid int(11) DEFAULT '-1' NOT NULL,