diff --git a/code/PostgreSQLDatabase.php b/code/PostgreSQLDatabase.php index 70b8038..758ce0a 100755 --- a/code/PostgreSQLDatabase.php +++ b/code/PostgreSQLDatabase.php @@ -953,6 +953,8 @@ class PostgreSQLDatabase extends SS_Database { $indexSpec=trim($indexSpec, '()'); $bits=explode(',', $indexSpec); $indexes="\"" . implode("\",\"", $bits) . "\""; + // if some of the indexes have already been quoted then we need to remove the suplus double quotes + $indexes = str_replace('""', '"', $indexes); //One last check: $existing=DB::query("SELECT tablename FROM pg_indexes WHERE indexname='" . strtolower($tableCol) . "';")->first(); diff --git a/docs/README.md b/docs/README.md index e754aca..e1caa79 100644 --- a/docs/README.md +++ b/docs/README.md @@ -1,6 +1,6 @@ # PostgreSQL Database Module -SilverStripe now has tentative support for PostgreSQL ('Postgres'). This available though a module which you can use after completing a successful MySQL installation. +SilverStripe now has tentative support for PostgreSQL ('Postgres') which is available though this module ## Requirements