Cloud
pg_get_partkeydef
The pg_get_partkeydef() function takes the identifier of a relation and returns NULL. Redpanda SQL accepts the call for PostgreSQL client compatibility.
Syntax
pg_get_partkeydef(relation_oid)
You can also call the function as pg_catalog.pg_get_partkeydef().
Parameters
-
relation_oid: Object identifier (OID) of a relation. The type can beoid,integer, orbigint.
Return type
text. The function returns NULL for every argument, including the OID of an existing table.
Examples
The function returns NULL for any OID:
SELECT pg_get_partkeydef(0);
The function also returns NULL for a table that exists:
SELECT relname, pg_get_partkeydef(oid) FROM pg_catalog.pg_class WHERE relname = 'orders';
Was this helpful?