Fixed an issue where the column order displayed was incorrect for exclusion constraints with multiple columns. #8430
parent
48a26e8979
commit
85290d4e61
|
|
@ -4,8 +4,8 @@
|
|||
|
||||
ALTER TABLE IF EXISTS testschema.tableforexclusion
|
||||
ADD CONSTRAINT "Exclusion_$%{}[]()&*^!@""'`\/#" EXCLUDE USING gist (
|
||||
(col1 + col3) WITH <>,
|
||||
col2 WITH <>)
|
||||
col2 WITH <>,
|
||||
(col1 + col3) WITH <>)
|
||||
WITH (FILLFACTOR=12)
|
||||
WHERE (col1 > 1)
|
||||
DEFERRABLE INITIALLY DEFERRED;
|
||||
|
|
|
|||
|
|
@ -4,8 +4,8 @@
|
|||
|
||||
ALTER TABLE IF EXISTS testschema.tableforexclusion
|
||||
ADD CONSTRAINT "Exclusion_$%{}[]()&*^!@""'`\/#" EXCLUDE USING gist (
|
||||
(col1 + col3) WITH <>,
|
||||
col2 WITH <>)
|
||||
col2 WITH <>,
|
||||
(col1 + col3) WITH <>)
|
||||
WITH (FILLFACTOR=12)
|
||||
WHERE (col1 > 1)
|
||||
DEFERRABLE INITIALLY DEFERRED;
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@
|
|||
UNION
|
||||
{% endif %}
|
||||
SELECT
|
||||
a.attnum,
|
||||
i.indoption[{{loop.index -1}}] AS options,
|
||||
pg_catalog.pg_get_indexdef(i.indexrelid, {{loop.index}}, true) AS coldef,
|
||||
op.oprname,
|
||||
|
|
@ -21,3 +22,4 @@ LEFT OUTER JOIN pg_catalog.pg_collation coll ON a.attcollation=coll.oid
|
|||
LEFT OUTER JOIN pg_catalog.pg_namespace nspc ON coll.collnamespace=nspc.oid
|
||||
WHERE i.indexrelid = {{cid}}::oid
|
||||
{% endfor %}
|
||||
ORDER BY attnum
|
||||
Loading…
Reference in New Issue