Fixed failures introduced by strict comparison

parent dca1465b
......@@ -212,7 +212,7 @@ class PostgreSqlSchemaManager extends AbstractSchemaManager
{
$buffer = [];
foreach ($tableIndexes as $row) {
$colNumbers = explode(' ', $row['indkey']);
$colNumbers = array_map('intval', explode(' ', $row['indkey']));
$colNumbersSql = 'IN (' . join(' ,', $colNumbers) . ' )';
$columnNameSql = "SELECT attnum, attname FROM pg_attribute
WHERE attrelid={$row['indrelid']} AND attnum $colNumbersSql ORDER BY attnum ASC;";
......
......@@ -70,14 +70,16 @@ class SQLServerSchemaManager extends AbstractSchemaManager
$tableColumn['name'] = '';
}
while ($default !== ($default2 = preg_replace('/^\((.*)\)$/', '$1', $default))) {
$default = trim($default2, "'");
if ($default !== null) {
while ($default !== ($default2 = preg_replace('/^\((.*)\)$/', '$1', $default))) {
$default = trim($default2, "'");
if ($default !== 'getdate()') {
continue;
}
if ($default !== 'getdate()') {
continue;
}
$default = $this->_platform->getCurrentTimestampSQL();
$default = $this->_platform->getCurrentTimestampSQL();
}
}
switch ($dbType) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment