数据仓库服务 GAUSSDB(DWS)-其它函数:get_volatile_pg_class(relname text)

时间:2024-11-28 17:38:53

get_volatile_pg_class(relname text)

描述:获取当前会话中指定volatile临时表相关的pg_class元数据。该函数仅8.2.0及以上集群版本支持。

参数:当前会话中volatile临时表表名。

返回值类型:record

返回值字段:

  • oid:返回volatile临时表的oid。
  • 其他字段:同pg_class系统表中的基础字段(不包括系统隐藏字段)。

示例:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
SELECT * FROM get_volatile_pg_class('tx1');
  oid  | relname | relnamespace | reltype | reloftype | relowner | relam | relfilenode | reltablespace | relpages | reltuples | relallvisible | reltoastrelid | reltoastidxid | reldeltarelid |
 reldeltaidx | relcudescrelid | relcudescidx | relhasindex | relisshared | relpersistence | relkind | relnatts | relchecks | relhasoids | relhaspkey | relhasrules | relhastriggers | relhassub
class | relcmprs | relhasclusterkey | relrowmovement | parttype | relfrozenxid | relacl |            reloptions            | relreplident | relfrozenxid64
-------+---------+--------------+---------+-----------+----------+-------+-------------+---------------+----------+-----------+---------------+---------------+---------------+---------------+
-------------+----------------+--------------+-------------+-------------+----------------+---------+----------+-----------+------------+------------+-------------+----------------+----------
------+----------+------------------+----------------+----------+--------------+--------+----------------------------------+--------------+----------------
 16772 | tx1     |        16770 |   16774 |         0 |       10 |     0 |       16772 |          1665 |        0 |         0 |             0 |         16775 |             0 |             0 |
           0 |              0 |            0 | f           | f           | v              | r       |        2 |         0 | f          | f          | f           | f              | f
      | 1        | f                | f              | n        | 11815        |        | {orientation=row,compression=no} | d            |          11815
(1 row)
support.huaweicloud.com/sqlreference-830-dws/dws_06_0062.html