Skip to content

Commit dcb6455

Browse files
committed
Fix same schema to treat pg_constraint.confmatchtype = 'u' = 's'
This relates to a change in the character representing a simple match on a foreign key stored in the confmatchtype field changing from 'u' to 's' between postgresql 9.2 and 9.3. Ref: http://www.postgresql.org/docs/9.2/static/catalog-pg-constraint.html http://www.postgresql.org/docs/9.3/static/catalog-pg-constraint.html
1 parent 3e5f5f7 commit dcb6455

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

check_postgres.pl

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1119,7 +1119,7 @@ package check_postgres;
11191119
SQL => q{
11201120
SELECT c.*, c.oid, n.nspname||'.'||c1.relname||'.'||c.conname AS name, quote_ident(c.conname) AS safename,
11211121
n.nspname AS schema, r.relname AS tname,
1122-
pg_get_constraintdef(c.oid) AS constraintdef
1122+
pg_get_constraintdef(c.oid) AS constraintdef, translate(c.confmatchtype,'u','s') AS confmatchtype_compat
11231123
FROM pg_constraint c
11241124
JOIN pg_class c1 ON (c1.oid = c.conrelid)
11251125
JOIN pg_namespace n ON (n.oid = c.connamespace)
@@ -6756,7 +6756,8 @@ sub check_same_schema {
67566756
indexprs,indcheckxmin,reltablespace,
67576757
indkey', '' ],
67586758
[trigger => 'tgqual,tgconstraint', '' ],
6759-
[constraint => 'conbin,conindid,conkey,confkey', '' ],
6759+
[constraint => 'conbin,conindid,conkey,confkey
6760+
confmatchtype', '' ],
67606761
[column => 'atttypid,attnum,attbyval,attndims', '' ],
67616762
);
67626763

0 commit comments

Comments
 (0)