Home Explore Blog CI



postgresql

100th chunk of `doc/src/sgml/catalogs.sgml`
5eb300eaf6ec04d9b15bbb831c11e4408c3aea5161dfccab0000000100000fa0
  <entry role="catalog_table_entry"><para role="column_definition">
       <structfield>tgargs</structfield> <type>bytea</type>
      </para>
      <para>
       Argument strings to pass to trigger, each NULL-terminated
      </para></entry>
     </row>

     <row>
      <entry role="catalog_table_entry"><para role="column_definition">
       <structfield>tgqual</structfield> <type>pg_node_tree</type>
      </para>
      <para>
       Expression tree (in <function>nodeToString()</function>
       representation) for the trigger's <literal>WHEN</literal> condition, or null
       if none
      </para></entry>
     </row>

     <row>
      <entry role="catalog_table_entry"><para role="column_definition">
       <structfield>tgoldtable</structfield> <type>name</type>
      </para>
      <para>
       <literal>REFERENCING</literal> clause name for <literal>OLD TABLE</literal>,
       or null if none
      </para></entry>
     </row>

     <row>
      <entry role="catalog_table_entry"><para role="column_definition">
       <structfield>tgnewtable</structfield> <type>name</type>
      </para>
      <para>
       <literal>REFERENCING</literal> clause name for <literal>NEW TABLE</literal>,
       or null if none
      </para></entry>
     </row>
    </tbody>
   </tgroup>
  </table>

  <para>
   Currently, column-specific triggering is supported only for
   <literal>UPDATE</literal> events, and so <structfield>tgattr</structfield> is relevant
   only for that event type.  <structfield>tgtype</structfield> might
   contain bits for other event types as well, but those are presumed
   to be table-wide regardless of what is in <structfield>tgattr</structfield>.
  </para>

  <note>
   <para>
    When <structfield>tgconstraint</structfield> is nonzero,
    <structfield>tgconstrrelid</structfield>, <structfield>tgconstrindid</structfield>,
    <structfield>tgdeferrable</structfield>, and <structfield>tginitdeferred</structfield> are
    largely redundant with the referenced <link linkend="catalog-pg-constraint"><structname>pg_constraint</structname></link> entry.
    However, it is possible for a non-deferrable trigger to be associated
    with a deferrable constraint: foreign key constraints can have some
    deferrable and some non-deferrable triggers.
   </para>
  </note>

  <note>
   <para>
    <literal>pg_class.relhastriggers</literal>
    must be true if a relation has any triggers in this catalog.
   </para>
  </note>

 </sect1>


 <sect1 id="catalog-pg-ts-config">
  <title><structname>pg_ts_config</structname></title>

  <indexterm zone="catalog-pg-ts-config">
   <primary>pg_ts_config</primary>
  </indexterm>

  <para>
   The <structname>pg_ts_config</structname> catalog contains entries
   representing text search configurations.  A configuration specifies
   a particular text search parser and a list of dictionaries to use
   for each of the parser's output token types.  The parser is shown
   in the <structname>pg_ts_config</structname> entry, but the
   token-to-dictionary mapping is defined by subsidiary entries in <link
   linkend="catalog-pg-ts-config-map"><structname>pg_ts_config_map</structname></link>.
  </para>

  <para>
   <productname>PostgreSQL</productname>'s text search features are
   described at length in <xref linkend="textsearch"/>.
  </para>

  <table>
   <title><structname>pg_ts_config</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>oid</structfield> <type>oid</type>
      </para>
      <para>
       Row identifier
      </para></entry>
     </row>

     <row>
      <entry role="catalog_table_entry"><para role="column_definition">
       <structfield>cfgname</structfield> <type>name</type>
  

Title: pg_trigger Catalog Columns (Continued) and Notes, Introduction to pg_ts_config
Summary
This section concludes the description of the `pg_trigger` catalog columns, including `tgnewtable` (REFERENCING NEW TABLE clause name). It provides notes regarding column-specific triggering limitations and redundancy between `pg_trigger` and `pg_constraint` when `tgconstraint` is non-zero. It also notes the importance of `pg_class.relhastriggers` being true if a relation has triggers. The section then transitions to introducing the `pg_ts_config` catalog, which stores text search configurations. It explains that a configuration specifies a text search parser and a list of dictionaries, with token-to-dictionary mapping defined in `pg_ts_config_map`.