Bug #19177
closedSQL engine parse ERROR: Field type unknown in parseFieldDef()!: near "datetime default '0000-00-00 00:00:00' "
0%
Description
After updating the extension list for updates, Typo3 died with message
SQL engine parse ERROR: Field type unknown in parseFieldDef()!: near "datetime default '0000-00-00 00:00:00' "
.
Patch is in ./t3lib/class.t3lib_sqlparser.php
Around line 999:
// Field type:
! if ($result['fieldType'] = $this->nextPart($parseString,'^(int|smallint|tinyint|mediumint|bigint|double|numeric|decimal|float|varchar|char|text|tinytext|mediumtext|longtext|blob|tinyblob|mediumblob|longblob|datetime)([[:space:],]+|\()')) {
replace
if ($result['fieldType'] = $this->nextPart($parseString,'^(int|smallint|tinyint|mediumint|bigint|double|numeric|decimal|float|varchar|char|text|tinytext|mediumtext|longtext|blob|tinyblob|mediumblob|longblob)([[:space:],]+|\()')) {
with
if ($result['fieldType'] = $this->nextPart($parseString,'^(int|smallint|tinyint|mediumint|bigint|double|numeric|decimal|float|varchar|char|text|tinytext|mediumtext|longtext|blob|tinyblob|mediumblob|longblob|datetime)([[:space:],]+|\()')) {
(issue imported from #M9093)
Updated by Susanne Moog about 14 years ago
AFAIK datetime is no real SQL data type but an invention of MySQL and should therefore not be used if you want to stay compatible to other DBMS.