camper/verify/season_calendar_season_id_fkey.sql
jordi fita mas dbbd06cf85 Change the verify for season_calendar_season_id_fkey
It failed in build.opensuse.org; possibly the view in information_scheme
is different.
2024-03-14 22:28:46 +01:00

15 lines
374 B
PL/PgSQL

-- Verify camper:season_calendar_season_id_fkey on pg
begin;
select 1/count(*)
from pg_constraint
where conrelid = 'camper.season_calendar'::regclass
and conname = 'season_calendar_season_id_fkey'
and contype = 'f'
and connamespace = 'camper'::regnamespace
and pg_get_constraintdef(oid) = 'FOREIGN KEY (season_id) REFERENCES camper.season(season_id)'
;
rollback;