Updated on 2024-05-07 GMT+08:00

PG_RANGE

PG_RANGE records information about range types, except for records of types in PG_TYPE.

Table 1 PG_RANGE columns

Name

Type

Reference

Description

rngtypid

oid

oid in PG_TYPE

OID of the range type

rngcollation

oid

oid in PG_COLLATION

OID of the collation used for range comparisons (0 if none)

rngsubopc

oid

oid in PG_OPCLASS

OID of the subtype's operator class used for range comparisons

rngcanonical

regproc

proname in PG_PROC

Name of the function to convert a range value into canonical form (0 if none)

rngsubdiff

regproc

proname in PG_PROC

Name of the function used to calculate the difference between two elements in a range. The return value of the function is of the double-precision type. If the function does not exist, the value of rngsubdiff is 0.

rngsubopc determines the sort ordering used by the range type. rngcanonical is used when the element type is discrete.