authen
.public
Tables
(current)
Columns
Constraints
Relationships
Orphan Tables
Anomalies
Routines
fn_report_service_settings
Parameters
Name
Type
Mode
Definition
with reports as ( select json_object_agg( r.report_filename, case r.report_type when 'print_form' then json_build_object('jrxml', '/jrxml/print_form/'||r.report_filename||'.jrxml') else json_build_object('jrxml', '/jrxml/'||r.report_filename||'.jrxml') end ) reports from reports r where r.report_filename is not null and not r.report_filename ilike '%.frx' ), connections as ( select json_object_agg( lower(code), json_build_object( 'jdbc', format('jdbc:postgresql://%s:%s/%s', coalesce(db_host, 'localhost'), coalesce(db_port, 5432)::text, coalesce(db_name, lower(code))), 'user', 'newsoft', 'password', 'News0ft@pg' ) ) as connections from property p where enabled = true ) select json_build_object( 'reports', reports, --(select reports from reports), 'connections', connections, --(select conn_str from connections), 'drivers', $JSON${"postgresql": { "path": "/libs/postgresql-42.2.5.jar", "class": "org.postgresql.Driver" } }$JSON$::json ) as settings from reports, connections