-- 迁移：业务库导入 BOARD 看板所需的 3 个 FDW 外部表
-- 日期：2026-03-19
-- 前置：ETL 库已执行 2026-03-19_add_board_rls_views.sql
-- 回滚：DROP FOREIGN TABLE IF EXISTS fdw_etl.v_dws_assistant_project_tag, fdw_etl.v_dws_member_project_tag, fdw_etl.v_dws_member_spending_power_index;

-- 从 ETL 库 app schema 导入 3 个新视图为外部表
IMPORT FOREIGN SCHEMA app
    LIMIT TO (
        v_dws_assistant_project_tag,
        v_dws_member_project_tag,
        v_dws_member_spending_power_index
    )
    FROM SERVER etl_feiqiu_server
    INTO fdw_etl;
