psql -af > out, is possible to also have raise notice, raise info part.

From: jian he <jian(dot)universality(at)gmail(dot)com>
To: pgsql-general list <pgsql-general(at)lists(dot)postgresql(dot)org>
Subject: psql -af > out, is possible to also have raise notice, raise info part.
Date: 2023-07-12 03:52:26
Message-ID: CACJufxFhzBCAikuQOStLt0VXLFEWJd4bgxzHvv7dVu-tOA+QZg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

hi.

test.sql content:
--------------------------------------------------------------------------------------------------
do $$
begin
raise info 'information message %', now() ;
raise debug 'debug message %', now();
raise notice 'notice message %', now();
end $$;
--------------------------------------------------------------------------------------------------
psql -af test.sql > test.out

current result:
--------------------------------------------------------------------------------------------------
do $$
begin
raise info 'information message %', now() ;
raise notice 'notice message %', now();
end $$;
DO
--------------------------------------------------------------------------------------------------
expected result in test.out

do $$
begin
raise info 'information message %', now() ;
raise notice 'notice message %', now();
end $$;
INFO: information message 2023-07-12 11:49:27.894126+08
NOTICE: notice message 2023-07-12 11:49:27.894126+08
DO

Responses

Browse pgsql-general by date

  From Date Subject
Next Message David G. Johnston 2023-07-12 04:05:51 Re: psql -af > out, is possible to also have raise notice, raise info part.
Previous Message Benedict Holland 2023-07-12 01:31:35 Re: Need Help On Upgrade