pg_identify_object return missing 'domain' keyword for domain constraints

From: Adam Thomas <althomas(at)agiledigital(dot)com(dot)au>
To: pgsql-bugs(at)lists(dot)postgresql(dot)org
Subject: pg_identify_object return missing 'domain' keyword for domain constraints
Date: 2023-01-11 06:04:15
Message-ID: CALudq5L7WfW0wu33pcwSPKde97qDrgJPQoMJ7GS2KYvm-Xe7SA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Hi,

When I call pg_identify_object on a domain constraint, it produces an
invalid identifier because it omits the 'domain' keyword.

For example, when running it against the us_postal_code_check constraint
from the Create Domain documentation (PostgreSQL 8.4.22 Documentation) - I
expect to receive "us_postal_code_check on domain public.us_postal_code",
but I actually receive "us_postal_code_check on public.us_postal_code".

I've attached a script which demonstrates the issue, as tested on the
postgres:latest docker image (Debian 15.1-1.pgdg110+1).

Adam

Attachment Content-Type Size
pg_identify_object-domain_constraint-test.sql application/octet-stream 1.4 KB

Browse pgsql-bugs by date

  From Date Subject
Next Message James Pang (chaolpan) 2023-01-11 06:17:04 RE: pg_logical_slot_peek_changes with slots created with pglogical_output missed DML records,
Previous Message Amit Kapila 2023-01-11 06:03:02 Re: pg_logical_slot_peek_changes with slots created with pglogical_output missed DML records,