-
Notifications
You must be signed in to change notification settings - Fork 0
/
pgsql11.properties
3 lines (3 loc) · 1.11 KB
/
pgsql11.properties
1
2
3
extends=pgsql
selectRoutinesSql=select r.routine_name, case p.prokind when 'f' then 'FUNCTION' when 'p' then 'PROCEDURE' when 'a' then 'AGGREGATE' when 'w' then 'WINDOW' else 'UNKNOWN' end as routine_type, case when p.proretset then 'SETOF ' else '' end || case when r.data_type = 'USER-DEFINED' then r.type_udt_name else r.data_type end as dtd_identifier, r.external_language as routine_body, r.routine_definition, r.sql_data_access, r.security_type, r.is_deterministic, d.description as routine_comment from information_schema.routines r left join pg_namespace ns on r.routine_schema = ns.nspname left join pg_proc p on ns.oid = p.pronamespace and r.routine_name = p.proname left join pg_description d on d.objoid = p.oid where r.routine_schema = :schema
selectRoutineParametersSql=select r.routine_name as specific_name, coalesce(p.parameter_name, '$' || p.ordinal_position) as parameter_name, p.data_type as dtd_identifier, p.parameter_mode from information_schema.parameters p left join information_schema.routines r on r.specific_name = p.specific_name where p.specific_schema = :schema order by p.specific_name, p.ordinal_position