primary key of partitioned table referenced by foreign table, v11, v12 clarification

From: Raj kumar <rajkumar820999(at)gmail(dot)com>
To: pgsql-admin(at)lists(dot)postgresql(dot)org
Subject: primary key of partitioned table referenced by foreign table, v11, v12 clarification
Date: 2020-02-20 09:44:56
Message-ID: CACxU--Xwzp=_7r0tuwe49jphAe07+7nEY130OuHcevX8fE1DPg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

Hi Team,

I am getting the below error when I am referencing Primary Key of parents
table from checking table in Postgres version 11. I went through
documentation of Postgres 12, where is mentioned that, "Primary key of the
partitioned table can be referenced by other foreign tables."

I would like to know if the below error is something that is fixed or
something else.

test=# insert into checking values(1,'tom',1);
ERROR: insert or update on table "checking" violates foreign key
constraint "checking_artist_fkey"
DETAIL: Key (artist)=(1) is not present in table "parent".
test=#

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Jeff Janes 2020-02-20 13:58:45 Re: primary key of partitioned table referenced by foreign table, v11, v12 clarification
Previous Message sandman42 2020-02-19 10:59:43 Tablespace size management questions