Commit 7068357d authored by Benjamin Eberlei's avatar Benjamin Eberlei

Merge pull request #475 from deeky666/fix-oracle-default-value-introspection

Fix column default value introspection in Oracle
parents f99f6edd 0573bbe5
...@@ -113,10 +113,16 @@ class OracleSchemaManager extends AbstractSchemaManager ...@@ -113,10 +113,16 @@ class OracleSchemaManager extends AbstractSchemaManager
$tableColumn['column_name'] = ''; $tableColumn['column_name'] = '';
} }
if (stripos($tableColumn['data_default'], 'NULL') !== null) { if ($tableColumn['data_default'] === 'NULL') {
$tableColumn['data_default'] = null; $tableColumn['data_default'] = null;
} }
if (null !== $tableColumn['data_default']) {
// Default values returned from database are enclosed in single quotes.
// Sometimes trailing spaces are also encountered.
$tableColumn['data_default'] = trim(trim($tableColumn['data_default']), "'");
}
$precision = null; $precision = null;
$scale = null; $scale = null;
......
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