gendesign/data/sql/99b_grant_quarter_price_index_fdw.sql
bot-backend 87a5de0cae
All checks were successful
Deploy Trade-In / changes (push) Successful in 6s
Deploy / changes (push) Successful in 5s
Deploy Trade-In / build-frontend (push) Has been skipped
Deploy / build-frontend (push) Has been skipped
Deploy Trade-In / test (push) Successful in 26s
Deploy Trade-In / build-backend (push) Successful in 25s
Deploy / build-backend (push) Successful in 1m30s
Deploy Trade-In / deploy (push) Successful in 37s
Deploy / build-worker (push) Successful in 2m54s
Deploy / deploy (push) Successful in 1m8s
feat(db): quarter_price_index FDW foreign table + monthly refresh (Refs #762) (#797)
Co-authored-by: bot-backend <bot-backend@gendsgn.local>
Co-committed-by: bot-backend <bot-backend@gendsgn.local>
2026-05-30 17:16:28 +00:00

16 lines
733 B
PL/PgSQL
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

-- 99b_grant_quarter_price_index_fdw.sql
-- Issue #762 (#647-2) — grant SELECT on mv_quarter_price_index to the tradein
-- FDW reader role so the tradein foreign table (085_quarter_price_index_fdw.sql)
-- can read it. Mirrors 122_grant_rosreestr_to_fdw_reader.sql.
--
-- Ordering: '99b_' sorts AFTER '99a_quarter_price_index.sql' (which CREATEs the MV)
-- because 'a' < 'b'. The MV must exist before the GRANT. Files 100_122_ sort
-- BEFORE 99_ lexicographically ('1' < '9'), so they cannot grant on this object.
-- Idempotent: GRANT is repeatable; role tradein_fdw_reader created in
-- 100_tradein_fdw_role.sql (REVOKE ALL baseline there).
BEGIN;
GRANT SELECT ON public.mv_quarter_price_index TO tradein_fdw_reader;
COMMIT;