From 0f79bffbec99aa10d6bc019da7dc7344d1376695 Mon Sep 17 00:00:00 2001 From: Allie Rowan Date: Wed, 10 Jul 2024 16:36:26 -0400 Subject: [PATCH] the CheckConstraint query returned constraints owned by extensions --- pyrseas/dbobject/constraint.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pyrseas/dbobject/constraint.py b/pyrseas/dbobject/constraint.py index f1413d7..12f932c 100644 --- a/pyrseas/dbobject/constraint.py +++ b/pyrseas/dbobject/constraint.py @@ -148,6 +148,8 @@ def query(dbversion=None): AND contype = 'c' AND contypid NOT IN (SELECT objid FROM pg_depend WHERE deptype = 'e' AND classid = 'pg_type'::regclass) + AND conrelid NOT IN (SELECT objid FROM pg_depend + WHERE deptype = 'e' AND classid = 'pg_class'::regclass) ORDER BY schema, "table", name""" @staticmethod