Cloud
pg_get_ruledef
The pg_get_ruledef() function takes the identifier of a rule and returns NULL. Redpanda SQL accepts the call for PostgreSQL client compatibility.
Syntax
pg_get_ruledef(rule_oid)
pg_get_ruledef(rule_oid, pretty_bool)
You can also call the function as pg_catalog.pg_get_ruledef().
Parameters
-
rule_oid: Object identifier (OID) of a rule. The type can beoid,integer, orbigint. -
pretty_bool: Optional. Boolean argument. The result isNULLfor either value.
Examples
The function returns NULL for any OID:
SELECT pg_get_ruledef(0);
The two-argument form also returns NULL:
SELECT pg_get_ruledef(0, true);
Was this helpful?