Home Explore Blog CI



postgresql

58th chunk of `doc/src/sgml/system-views.sgml`
df2cfb1432133a37bcd9b76a60e9fd7b2187bc74cf5332530000000100000fa0
    </para>
      <para>
       True if currently observing daylight savings
      </para></entry>
     </row>
    </tbody>
   </tgroup>
  </table>

 </sect1>

 <sect1 id="view-pg-user">
  <title><structname>pg_user</structname></title>

  <indexterm zone="view-pg-user">
   <primary>pg_user</primary>
  </indexterm>

  <para>
   The view <structname>pg_user</structname> provides access to
   information about database users.  This is simply a publicly
   readable view of
   <link linkend="view-pg-shadow"><structname>pg_shadow</structname></link>
   that blanks out the password field.
  </para>

  <table>
   <title><structname>pg_user</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>usename</structfield> <type>name</type>
      </para>
      <para>
       User name
      </para></entry>
     </row>

     <row>
      <entry role="catalog_table_entry"><para role="column_definition">
       <structfield>usesysid</structfield> <type>oid</type>
      </para>
      <para>
       ID of this user
      </para></entry>
     </row>

     <row>
      <entry role="catalog_table_entry"><para role="column_definition">
       <structfield>usecreatedb</structfield> <type>bool</type>
      </para>
      <para>
       User can create databases
      </para></entry>
     </row>

     <row>
      <entry role="catalog_table_entry"><para role="column_definition">
       <structfield>usesuper</structfield> <type>bool</type>
      </para>
      <para>
       User is a superuser
      </para></entry>
     </row>

     <row>
      <entry role="catalog_table_entry"><para role="column_definition">
       <structfield>userepl</structfield> <type>bool</type>
      </para>
      <para>
       User can initiate streaming replication and put the system in and
       out of backup mode.
      </para></entry>
     </row>

     <row>
      <entry role="catalog_table_entry"><para role="column_definition">
       <structfield>usebypassrls</structfield> <type>bool</type>
      </para>
      <para>
       User bypasses every row-level security policy, see
       <xref linkend="ddl-rowsecurity"/> for more information.
      </para></entry>
     </row>

     <row>
      <entry role="catalog_table_entry"><para role="column_definition">
       <structfield>passwd</structfield> <type>text</type>
      </para>
      <para>
       Not the password (always reads as <literal>********</literal>)
      </para></entry>
     </row>

     <row>
      <entry role="catalog_table_entry"><para role="column_definition">
       <structfield>valuntil</structfield> <type>timestamptz</type>
      </para>
      <para>
       Password expiry time (only used for password authentication)
      </para></entry>
     </row>

     <row>
      <entry role="catalog_table_entry"><para role="column_definition">
       <structfield>useconfig</structfield> <type>text[]</type>
      </para>
      <para>
       Session defaults for run-time configuration variables
      </para></entry>
     </row>
    </tbody>
   </tgroup>
  </table>

 </sect1>

 <sect1 id="view-pg-user-mappings">
  <title><structname>pg_user_mappings</structname></title>

  <indexterm zone="view-pg-user-mappings">
   <primary>pg_user_mappings</primary>
  </indexterm>

  <para>
   The view <structname>pg_user_mappings</structname> provides access
   to information about user mappings.  This is essentially a publicly
   readable view of
   <link linkend="catalog-pg-user-mapping"><structname>pg_user_mapping</structname></link>
   that leaves out the options field if the user has no rights to use
   it.
  </para>

  <table>
   <title><structname>pg_user_mappings</structname> Columns</title>
   <tgroup cols="1">
    <thead>
 

Title: System Views: pg_user and pg_user_mappings
Summary
The views pg_user and pg_user_mappings provide information about database users and user mappings, with pg_user showing details such as user name, ID, database creation privileges, and superuser status, and pg_user_mappings offering a publicly readable view of user mapping information, excluding certain fields for users without proper rights.