Skip to content

Commit a196e67

Browse files
committed
Fix object identities for pg_conversion objects
We were neglecting to schema-qualify them. Backpatch to 9.3, where object identities were introduced as a concept by commit f8348ea.
1 parent a7ad5cf commit a196e67

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

src/backend/catalog/objectaddress.c

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2785,15 +2785,19 @@ getObjectIdentity(const ObjectAddress *object)
27852785
{
27862786
HeapTuple conTup;
27872787
Form_pg_conversion conForm;
2788+
char *schema;
27882789

27892790
conTup = SearchSysCache1(CONVOID,
27902791
ObjectIdGetDatum(object->objectId));
27912792
if (!HeapTupleIsValid(conTup))
27922793
elog(ERROR, "cache lookup failed for conversion %u",
27932794
object->objectId);
27942795
conForm = (Form_pg_conversion) GETSTRUCT(conTup);
2795-
appendStringInfo(&buffer, "%s",
2796-
quote_identifier(NameStr(conForm->conname)));
2796+
schema = get_namespace_name(conForm->connamespace);
2797+
appendStringInfoString(&buffer,
2798+
quote_qualified_identifier(schema,
2799+
NameStr(conForm->conname)));
2800+
pfree(schema);
27972801
ReleaseSysCache(conTup);
27982802
break;
27992803
}

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy