Home Explore Blog CI



postgresql

4th chunk of `doc/src/sgml/datetime.sgml`
65c41657545cdc6cd2012926230f2750671c708b9a8134730000000100000fa0
   <entry>Apr</entry>
       </row>
       <row>
        <entry>May</entry>
        <entry></entry>
       </row>
       <row>
        <entry>June</entry>
        <entry>Jun</entry>
       </row>
       <row>
        <entry>July</entry>
        <entry>Jul</entry>
       </row>
       <row>
        <entry>August</entry>
        <entry>Aug</entry>
       </row>
       <row>
        <entry>September</entry>
        <entry>Sep, Sept</entry>
       </row>
       <row>
        <entry>October</entry>
        <entry>Oct</entry>
       </row>
       <row>
        <entry>November</entry>
        <entry>Nov</entry>
       </row>
       <row>
        <entry>December</entry>
        <entry>Dec</entry>
       </row>
      </tbody>
     </tgroup>
    </table>

    <para>
     <xref linkend="datetime-dow-table"/> shows the tokens that are
     recognized as names of days of the week.
    </para>

     <table id="datetime-dow-table">
      <title>Day of the Week Names</title>
      <tgroup cols="2">
       <thead>
        <row>
         <entry>Day</entry>
         <entry>Abbreviations</entry>
        </row>
       </thead>
       <tbody>
        <row>
         <entry>Sunday</entry>
         <entry>Sun</entry>
        </row>
        <row>
         <entry>Monday</entry>
         <entry>Mon</entry>
        </row>
        <row>
         <entry>Tuesday</entry>
         <entry>Tue, Tues</entry>
        </row>
        <row>
         <entry>Wednesday</entry>
         <entry>Wed, Weds</entry>
        </row>
        <row>
         <entry>Thursday</entry>
         <entry>Thu, Thur, Thurs</entry>
        </row>
        <row>
         <entry>Friday</entry>
         <entry>Fri</entry>
        </row>
        <row>
         <entry>Saturday</entry>
         <entry>Sat</entry>
        </row>
       </tbody>
      </tgroup>
     </table>

   <para>
    <xref linkend="datetime-mod-table"/> shows the tokens that serve
    various modifier purposes.
   </para>

    <table id="datetime-mod-table">
     <title>Date/Time Field Modifiers</title>
     <tgroup cols="2">
      <thead>
       <row>
        <entry>Identifier</entry>
        <entry>Description</entry>
       </row>
      </thead>
      <tbody>
       <row>
        <entry><literal>AM</literal></entry>
        <entry>Time is before 12:00</entry>
       </row>
       <row>
        <entry><literal>AT</literal></entry>
        <entry>Ignored</entry>
       </row>
       <row>
        <entry><literal>JULIAN</literal>, <literal>JD</literal>, <literal>J</literal></entry>
        <entry>Next field is Julian Date</entry>
       </row>
       <row>
        <entry><literal>ON</literal></entry>
        <entry>Ignored</entry>
       </row>
       <row>
        <entry><literal>PM</literal></entry>
        <entry>Time is on or after 12:00</entry>
       </row>
       <row>
        <entry><literal>T</literal></entry>
        <entry>Next field is time</entry>
       </row>
      </tbody>
     </tgroup>
    </table>
  </sect1>

  <sect1 id="datetime-config-files">
  <title>Date/Time Configuration Files</title>

   <indexterm>
    <primary>time zone</primary>
    <secondary>input abbreviations</secondary>
   </indexterm>

   <para>
    Since timezone abbreviations are not well standardized,
    <productname>PostgreSQL</productname> provides a means to customize
    the set of abbreviations accepted in datetime input.
    There are two sources for these abbreviations:

    <orderedlist>
     <listitem>
      <para>
       The <xref linkend="guc-timezone"/> run-time parameter is usually
       set to the name of an entry in the IANA time zone database.
       If that zone has widely-used zone abbreviations, they will appear
       in the IANA data, and <productname>PostgreSQL</productname> will
       preferentially recognize those abbreviations with the meanings
       given in the IANA data.
       For example, if <varname>timezone</varname> is set
       to <literal>America/New_York</literal> then <literal>EST</literal>
      

Title: Date and Time Formatting in PostgreSQL
Summary
PostgreSQL recognizes specific tokens for months, days of the week, and date/time field modifiers, and allows customization of time zone abbreviations through the IANA time zone database and configuration files, enabling flexible and standardized date and time input and processing.