fixed loading constraints #734

This commit is contained in:
SPRINX0\prochazka
2024-12-13 16:27:14 +01:00
parent a810dc4204
commit deb13505b8
7 changed files with 38 additions and 40 deletions

View File

@@ -7,6 +7,7 @@ select
key_column_usage.column_name as "column_name"
from information_schema.table_constraints
inner join information_schema.key_column_usage on table_constraints.table_name = key_column_usage.table_name and table_constraints.constraint_name = key_column_usage.constraint_name
and table_constraints.table_schema = key_column_usage.table_schema
where
table_constraints.table_schema !~ '^_timescaledb_'
and table_constraints.constraint_type = 'PRIMARY KEY'