Re: Postgres 11: Table Partitioning and Primary Keys

Michael Paquier <[email protected]>
Newsgroups gmane.comp.db.postgresql.devel.general,gmane.comp.db.postgresql.devel.documentation
Message-ID <[email protected]>
On Mon, Jul 08, 2019 at 11:10:51PM -0400, Tom Lane wrote:
> Isn't it the other way around, that the partition key column(s) must
> be
> included in the primary key?  Maybe I'm confused, but it seems like
> we couldn't enforce PK uniqueness otherwise.

Yes you are right.  The full column list of the partition key needs to
be included in the constraint, but that's not true the other way
around.
--
Michael
signature.asc (application/pgp-signature, 833 B)
-----BEGIN PGP SIGNATURE-----

iQIzBAABCgAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAl0kOPQACgkQnvQgOdby
QH2lDA/+NsrKgGouWCsYyo43jrylNaF99Bk0V6NwQMHyrI3/vAH4ifEOsGrqcxjH
E79d+LWkm3G01z3uA8GwSg6wrn0f1V/Wr3bDCgmG0xqcMyndsqku1qcqQiiApF+N
fR7wGKf3J6MPKHaSI6rgoD4RT/sl43PGL/2HGTm0GK6IWcJHRAWHIKYWH92X0+nu
aa4RaqPDNAJyeknO9+8PQhG7jfXa50AwUvXCqiWsbXLTUReQEjMBZZKD6lC1q3Lk
wRkey62EdLNwQJiH+jTQXUoynOI5p/q9XiFEQPX2wy/pqbmpxFtGVUh5mNkQhsiK
hnIq1GlN/elM1IJnx2i0zvubLW2vH5pgdJvM7gnZ3fMrPoOWj2hLR/ICtuWtYy6h
U758s8xZ88TNeUT7CFtrS5B9uteARX2GGlwoGy8icJiX9+4q5PsafV3WTY9vGzYX
g5AStceZ/7PPYq6CSlV4faKYGfdGevlGGcT5OFWQHkB/SW8eanixb+1rGAY/dCTq
sVwD8JFAKFv1MfV1A/0tBcXvlVU0WrnwIKy6+JDADMElgIpZejK4f7IlioG/j1v2
Llss4IR1CLHtGI7yLiV3wCpJhefEiZp9OKHO6eGPnxDGhf7kkaC+y/xJaiaY7bEq
ZnZZ3W9LlDje/JGQmKMaf5+Lyu4BJ+VKb0BJlDEDDuHUL6s0Kug=
=e4D2
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.