Fix objectaddress.c code for publication relations. getObjectDescription and getObjectIdentity failed to schema-qualify the name of the published table, which is bad in getObjectDescription and unforgivable in getObjectIdentity. Actually, getObjectIdentity failed to emit the table's name at all unless "objname" output is requested, which accidentally works for some (all?) extant callers but is clearly not the intended API. Somebody had also not gotten the memo that the output of getObjectIdentity is not to be translated.
To fix getObjectDescription, I made it call getRelationDescription, which required refactoring the translatable string for the case, but is more future-proof in case we ever publish relations that aren't plain tables. While at it, I made the English output look like "publication of table X in publication Y"; the added "of" seems to me to make it read much better. Back-patch to v10 where publications were introduced. Discussion: https://postgr.es/m/20180522.182020.114074746.horiguchi.kyot...@lab.ntt.co.jp Branch ------ master Details ------- https://git.postgresql.org/pg/commitdiff/1a31baf61ed81a13d034bd50db19473ad67acc52 Modified Files -------------- src/backend/catalog/objectaddress.c | 21 +++++++++++++-------- src/test/regress/expected/object_address.out | 2 +- 2 files changed, 14 insertions(+), 9 deletions(-)