Skip to content

Commit

Permalink
Add support for PostgreSQL 12 #708 (#709)
Browse files Browse the repository at this point in the history
  • Loading branch information
ganiuszka authored Mar 9, 2020
1 parent 6516f9a commit 9769c3e
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions framework/Data/Common/Pgsql/TPgsqlMetaData.php
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ protected function createTableInfo($table)
a.attname,
pg_catalog.format_type(a.atttypid, a.atttypmod) as type,
a.atttypmod,
a.attnotnull, a.atthasdef, adef.adsrc,
a.attnotnull, a.atthasdef, pg_get_expr(adef.adbin, adef.adrelid) AS adsrc,
(
SELECT 1 FROM pg_catalog.pg_depend pd, pg_catalog.pg_class pc
WHERE pd.objid=pc.oid
Expand Down Expand Up @@ -295,11 +295,7 @@ protected function getConstraintKeys($schemaName, $tableName)
SELECT conname, consrc, contype, indkey, indisclustered FROM (
SELECT
conname,
CASE WHEN contype='f' THEN
pg_catalog.pg_get_constraintdef(oid)
ELSE
'CHECK (' || consrc || ')'
END AS consrc,
pg_catalog.pg_get_constraintdef(oid) AS consrc,
contype,
conrelid AS relid,
NULL AS indkey,
Expand Down

0 comments on commit 9769c3e

Please sign in to comment.