Project

General

Profile

Bug #14790 » notyetcomplete.diff

Administrator Admin, 2005-10-18 17:40

View differences:

t3lib\class.t3lib_install.php 2005-10-18 17:37:56.000000000 +-0200
foreach($lines as $value) {
if ($value[0]!='#') {
if (!$isTable) {
$parts = explode(' ',$value);
if ($parts[0]=='CREATE' && $parts[1]=='TABLE') {
$isTable = $parts[2];
$isTable = str_replace( '`', '', $parts[2]);
if (TYPO3_OS=='WIN') { // tablenames are always lowercase on windows!
$isTable = strtolower($isTable);
}
}
} else {
if (substr($value,0,1)==')' && substr($value,-1)==';') {
......
}
// Change order of "default" and "null" statements
$parts[1] = preg_replace('/(.*) (default .*) (NOT NULL)/', '$1 $3 $2', $parts[1]);
$parts[1] = preg_replace('/(.*) (default .*) (NULL)/', '$1 $3 $2', $parts[1]);
if ($parts[0]!='PRIMARY' && $parts[0]!='KEY' && $parts[0]!='UNIQUE') {
$total[$isTable]['fields'][$parts[0]] = $parts[1];
$total[$isTable]['fields'][str_replace( '`', '', $parts[0])] = $parts[1];
} else {
$newParts = explode(' ',$parts[1],2);
$total[$isTable]['keys'][($parts[0]=='PRIMARY'?$parts[0]:$newParts[0])] = $lineV;
$total[$isTable]['keys'][($parts[0]=='PRIMARY'?$parts[0]:$newParts[0])] = str_replace( '`', '', $lineV);
}
}
}
}
}
(4-4/4)