BUG #17753: pg_dump --if-exists bug

From: PG Bug reporting form <noreply(at)postgresql(dot)org>
To: pgsql-bugs(at)lists(dot)postgresql(dot)org
Cc: justin(at)tonic(dot)ai
Subject: BUG #17753: pg_dump --if-exists bug
Date: 2023-01-18 22:33:15
Message-ID: 17753-9c8773631747ee1c@postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

The following bug has been logged on the website:

Bug reference: 17753
Logged by: Justin Zhang
Email address: justin(at)tonic(dot)ai
PostgreSQL version: 15.1
Operating system: MacOS 12.6
Description:

Running pg_dump with the options "--section=pre-data --no-owner
--no-privileges --no-subscriptions --no-publications --clean --if-exists
--file=/Users/ju5tinz/Dev/pg_pass_test/pre_data.sql" prints the warning:
pg_dump: warning: could not find where to insert IF EXISTS in statement "--
*not* dropping schema, since initdb creates it
"

Seems like pg_dump is trying to add the IF EXISTS operator to a comment
because of the --if-exists option. Tested this in v14 and the warning does
not appear. Also, the sql file is generated successfully.

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Noah Misch 2023-01-19 05:30:47 Re: index not used for bigint without explicit cast
Previous Message Sam.Mesh 2023-01-18 21:43:43 Re: index not used for bigint without explicit cast