Home Explore Blog CI



postgresql

55th chunk of `doc/src/sgml/catalogs.sgml`
1cf0d4f589d5bbae57bfd5e1e4f90923855c01212de639030000000100000fa5
 (<structfield>indnkeyatts</structfield> values), this contains the OID
       of the collation to use for the index, or zero if the column is not of
       a collatable data type.
      </para></entry>
     </row>

     <row>
      <entry role="catalog_table_entry"><para role="column_definition">
       <structfield>indclass</structfield> <type>oidvector</type>
       (references <link linkend="catalog-pg-opclass"><structname>pg_opclass</structname></link>.<structfield>oid</structfield>)
      </para>
      <para>
       For each column in the index key
       (<structfield>indnkeyatts</structfield> values), this contains the OID
       of the operator class to use.  See
       <link linkend="catalog-pg-opclass"><structname>pg_opclass</structname></link> for details.
      </para></entry>
     </row>

     <row>
      <entry role="catalog_table_entry"><para role="column_definition">
       <structfield>indoption</structfield> <type>int2vector</type>
      </para>
      <para>
       This is an array of <structfield>indnkeyatts</structfield> values that
       store per-column flag bits.  The meaning of the bits is defined by
       the index's access method.
      </para></entry>
     </row>

     <row>
      <entry role="catalog_table_entry"><para role="column_definition">
       <structfield>indexprs</structfield> <type>pg_node_tree</type>
      </para>
      <para>
       Expression trees (in <function>nodeToString()</function>
       representation) for index attributes that are not simple column
       references.  This is a list with one element for each zero
       entry in <structfield>indkey</structfield>.  Null if all index attributes
       are simple references.
      </para></entry>
     </row>

     <row>
      <entry role="catalog_table_entry"><para role="column_definition">
       <structfield>indpred</structfield> <type>pg_node_tree</type>
      </para>
      <para>
       Expression tree (in <function>nodeToString()</function>
       representation) for partial index predicate.  Null if not a
       partial index.
      </para></entry>
     </row>
    </tbody>
   </tgroup>
  </table>

 </sect1>


 <sect1 id="catalog-pg-inherits">
  <title><structname>pg_inherits</structname></title>

  <indexterm zone="catalog-pg-inherits">
   <primary>pg_inherits</primary>
  </indexterm>

  <para>
   The catalog <structname>pg_inherits</structname> records information about
   table and index inheritance hierarchies.  There is one entry for each direct
   parent-child table or index relationship in the database.  (Indirect
   inheritance can be determined by following chains of entries.)
  </para>

  <table>
   <title><structname>pg_inherits</structname> Columns</title>
   <tgroup cols="1">
    <thead>
     <row>
      <entry role="catalog_table_entry"><para role="column_definition">
       Column Type
      </para>
      <para>
       Description
      </para></entry>
     </row>
    </thead>

    <tbody>
     <row>
      <entry role="catalog_table_entry"><para role="column_definition">
       <structfield>inhrelid</structfield> <type>oid</type>
       (references <link linkend="catalog-pg-class"><structname>pg_class</structname></link>.<structfield>oid</structfield>)
      </para>
      <para>
       The OID of the child table or index
      </para></entry>
     </row>

     <row>
      <entry role="catalog_table_entry"><para role="column_definition">
       <structfield>inhparent</structfield> <type>oid</type>
       (references <link linkend="catalog-pg-class"><structname>pg_class</structname></link>.<structfield>oid</structfield>)
      </para>
      <para>
       The OID of the parent table or index
      </para></entry>
     </row>

     <row>
      <entry role="catalog_table_entry"><para role="column_definition">
       <structfield>inhseqno</structfield> <type>int4</type>
      </para>
      <para>
       If there is more than one direct parent for a child table (multiple
       inheritance), this number tells the order

Title: pg_index Columns (Cont.) and pg_inherits Table
Summary
This section describes remaining columns of the 'pg_index' catalog table: 'indoption' (per-column flag bits defined by the index's access method), 'indexprs' (expression trees for index attributes that are not simple column references), and 'indpred' (expression tree for partial index predicate). It also introduces the 'pg_inherits' catalog, which records information about table and index inheritance hierarchies. The table includes columns 'inhrelid' (OID of the child table or index), 'inhparent' (OID of the parent table or index), and 'inhseqno' (order of inheritance).