Загрузка данных


select
    n.nspname as schema_name,
    p.proname as object_name,
    case p.prokind
        when 'f' then 'FUNCTION'
        when 'p' then 'PROCEDURE'
        when 'a' then 'AGGREGATE'
        when 'w' then 'WINDOW FUNCTION'
    end as object_type,
    pg_get_function_identity_arguments(p.oid) as arguments
from pg_proc p
join pg_namespace n
    on n.oid = p.pronamespace
where p.prosrc ilike '%ft_dwh_get__pension_account_operation%'
order by n.nspname, p.proname;







select
    schemaname as schema_name,
    viewname as object_name,
    'VIEW' as object_type
from pg_views
where definition ilike '%ft_dwh_get__pension_account_operation%'
order by schemaname, viewname;





select
    schemaname as schema_name,
    matviewname as object_name,
    'MATERIALIZED VIEW' as object_type
from pg_matviews
where definition ilike '%ft_dwh_get__pension_account_operation%'
order by schemaname, matviewname;