OSDN Git Service

Be a bit more verbose about the effects of string literal processing
[pg-rex/syncrep.git] / doc / src / sgml / release-8.4.sgml
1 <!-- $PostgreSQL: pgsql/doc/src/sgml/release-8.4.sgml,v 1.9 2009/06/08 14:57:21 tgl Exp $ -->
2 <!-- See header comment in release.sgml about typical markup -->
3
4  <sect1 id="release-8-4">
5   <title>Release 8.4</title>
6
7   <note>
8    <title>Release date</title>
9    <simpara>2009-??-??, ITEMS CURRENT AS OF 2009-05-14</simpara>
10   </note>
11
12   <sect2>
13    <title>Overview</title>
14
15    <para>
16     After many years of development, <productname>PostgreSQL</> has
17     become feature-complete in many areas.   This release shows a
18     targeted approach to adding features (e.g., authentication,
19     monitoring, space reuse), and adds capabilities defined in the
20     later SQL standards.  The major areas of enhancement are:
21    </para>
22
23    <itemizedlist>
24
25     <!-- This list duplicates items below, but without authors or details-->
26
27     <listitem>
28      <para>
29       Windowing Functions
30      </para>
31     </listitem>
32
33     <listitem>
34      <para>
35       Common Table Expressions and Recursive Joins
36      </para>
37     </listitem>
38
39     <listitem>
40      <para>
41       Default and variadic parameters for functions
42      </para>
43     </listitem>
44
45     <listitem>
46      <para>
47       Parallel Restore
48      </para>
49     </listitem>
50
51     <listitem>
52      <para>
53       Column Permissions
54      </para>
55     </listitem>
56
57     <listitem>
58      <para>
59       Per-database locale settings
60      </para>
61     </listitem>
62
63     <listitem>
64      <para>
65       Improved hash indexes
66      </para>
67     </listitem>
68
69     <listitem>
70      <para>
71       Improved join performance for <literal>EXISTS</> and <literal>NOT EXISTS</> queries
72      </para>
73     </listitem>
74
75     <listitem>
76      <para>
77       Easier-to-use Warm Standby
78      </para>
79     </listitem>
80
81     <listitem>
82      <para>
83       Automatic sizing of the Free Space Map
84      </para>
85     </listitem>
86
87     <listitem>
88      <para>
89       Visibility Map (greatly reduces vacuum overhead for slowly-changing tables)
90      </para>
91     </listitem>
92
93     <listitem>
94      <para>
95       Version-aware psql (backslash commands work against older servers)
96      </para>
97     </listitem>
98
99     <listitem>
100      <para>
101       Support SSL certificates for user authentication
102      </para>
103     </listitem>
104
105     <listitem>
106      <para>
107       Per-function runtime statistics
108      </para>
109     </listitem>
110
111     <listitem>
112      <para>
113       Easy editing of functions in psql
114      </para>
115     </listitem>
116
117     <listitem>
118      <para>
119       New contrib modules: pg_stat_statements, auto_explain, citext, btree_gin
120      </para>
121     </listitem>
122
123    </itemizedlist>
124
125    <para>
126     The above items are explained in more detail in the sections below.
127    </para>
128
129   </sect2>
130
131   <sect2>
132    <title>Migration to Version 8.4</title>
133
134    <para>
135     A dump/restore using <application>pg_dump</application> is
136     required for those wishing to migrate data from any previous
137     release.
138    </para>
139
140    <para>
141     Observe the following incompatibilities:
142    </para>
143
144    <sect3>
145     <title>General</title>
146     <itemizedlist>
147
148      <listitem>
149       <para>
150        Use 64-bit integer datetimes by default (Neil Conway)
151       </para>
152
153       <para>
154        Previously this was selected by <application>configure</>'s
155        <option>--enable-integer-datetimes</> option.  To retain
156        the old behavior, build with <option>--disable-integer-datetimes</>.
157       </para>
158      </listitem>
159
160      <listitem>
161       <para>
162        Remove <application>ipcclean</> utility command (Bruce)
163       </para>
164
165       <para>
166        The utility only worked on a few platforms.  Users should use
167        their operating system tools instead.
168       </para>
169      </listitem>
170
171     </itemizedlist>
172
173    </sect3>
174
175    <sect3>
176     <title>Server Settings</title>
177     <itemizedlist>
178
179      <listitem>
180       <para>
181        Change default setting for
182        <literal>log_min_messages</> to <literal>warning</> (previously
183        it was <literal>notice</>) to reduce log file volume (Tom)
184       </para>
185      </listitem>
186
187      <listitem>
188       <para>
189        Change default setting for <literal>max_prepared_transactions</> to
190        zero (previously it was 5) (Tom)
191       </para>
192      </listitem>
193
194      <listitem>
195       <para>
196        Make <literal>debug_print_parse</>, <literal>debug_print_rewritten</>,
197        and <literal>debug_print_plan</>
198        output appear at <literal>LOG</> message level, not
199        <literal>DEBUG1</> as formerly (Tom)
200       </para>
201      </listitem>
202
203      <listitem>
204       <para>
205        Make <literal>debug_pretty_print</> default to <literal>on</> (Tom)
206       </para>
207      </listitem>
208
209      <listitem>
210       <para>
211        Remove <varname>explain_pretty_print</> parameter (no longer needed) (Tom)
212       </para>
213      </listitem>
214
215      <listitem>
216       <para>
217        Make <varname>log_temp_files</> settable by superusers only, like other
218        logging options (Simon Riggs)
219       </para>
220      </listitem>
221
222      <listitem>
223       <para>
224        Remove automatic appending of the epoch timestamp when no <literal>%</>
225        escapes are present in <literal>log_filename</> (Robert Haas)
226       </para>
227
228       <para>
229        This change was made because some users wanted a fixed log filename,
230        for use with an external log rotation tool.
231       </para>
232      </listitem>
233
234      <listitem>
235       <para>
236        Remove <varname>log_restartpoints</> from <filename>recovery.conf</>;
237        instead use <varname>log_checkpoints</> (Simon)
238       </para>
239      </listitem>
240
241      <listitem>
242       <para>
243        Remove <varname>krb_realm</> and <varname>krb_server_hostname</>;
244        these are now set in <filename>pg_hba.conf</> instead (Magnus)
245       </para>
246      </listitem>
247
248      <listitem>
249       <para>
250        There are also significant changes in <link
251        linkend="release-8-4-pg-hba-conf"><filename>pg_hba.conf</></link>,
252        as described below.
253       </para>
254      </listitem>
255
256     </itemizedlist>
257
258    </sect3>
259
260    <sect3>
261     <title>Queries</title>
262
263     <itemizedlist>
264
265      <listitem>
266       <para>
267        Change <command>TRUNCATE</> and <command>LOCK</> to
268        apply to child tables of the specified table(s) (Peter)
269       </para>
270
271       <para>
272        These commands now accept an <literal>ONLY</> option that prevents
273        processing child tables; this option must be used if the old
274        behavior is needed.
275       </para>
276      </listitem>
277
278      <listitem>
279       <para>
280        <command>SELECT DISTINCT</> and
281        <literal>UNION</>/<literal>INTERSECT</>/<literal>EXCEPT</>
282        no longer always produce sorted output (Tom)
283       </para>
284
285       <para>
286        Previously, these types of queries always removed duplicate rows
287        by means of Sort/Unique processing (i.e., sort then remove adjacent
288        duplicates).  Now they can be implemented by hashing, which will not
289        produce sorted output.  If an application relied on the output being
290        in sorted order, the recommended fix is to add an <literal>ORDER BY</>
291        clause.  As a short-term workaround, the previous behavior can be
292        restored by disabling <literal>enable_hashagg</>, but that is a very
293        performance-expensive fix.  <literal>SELECT DISTINCT ON</> never uses
294        hashing, however, so its behavior is unchanged.
295       </para>
296      </listitem>
297
298      <listitem>
299       <para>
300        Force child tables to inherit <literal>CHECK</> constraints from parents
301        (Alex Hunsaker, Nikhil Sontakke, Tom)
302       </para>
303
304       <para>
305        Formerly it was possible to drop such a constraint from a child
306        table, allowing rows that violate the constraint to be visible
307        when scanning the parent table.  This was deemed inconsistent,
308        as well as contrary to SQL standard.
309       </para>
310      </listitem>
311
312      <listitem>
313       <para>
314        Disallow negative <literal>LIMIT</> or <literal>OFFSET</>
315        values, rather than treating them as zero (Simon)
316       </para>
317      </listitem>
318
319      <listitem>
320       <para>
321        Disallow <command>LOCK TABLE</> outside a transaction block
322        (Tom)
323       </para>
324
325       <para>
326        Such an operation is useless because the lock would be released
327        immediately.
328       </para>
329      </listitem>
330
331      <listitem>
332       <para>
333        Sequences now contain an additional <structfield>start_value</> column
334        (Zoltan Boszormenyi)
335       </para>
336
337       <para>
338        This supports <command>ALTER SEQUENCE ... RESTART</>.
339       </para>
340      </listitem>
341
342     </itemizedlist>
343
344    </sect3>
345
346
347    <sect3>
348     <title>Functions and Operators</title>
349
350     <itemizedlist>
351
352      <listitem>
353       <para>
354        Make <type>numeric</> zero raised to a fractional power return
355        <literal>0</>, rather than throwing an error, and make
356        <type>numeric</> zero raised to the zero power return <literal>1</>,
357        rather than error (Bruce)
358       </para>
359
360       <para>
361        This matches the longstanding <type>float8</> behavior.
362       </para>
363      </listitem>
364
365      <listitem>
366       <para>
367        Allow unary minus of floating-point values to produce minus zero (Tom)
368       </para>
369
370       <para>
371        The changed behavior is more <acronym>IEEE</>-standard
372        compliant.
373       </para>
374      </listitem>
375
376      <listitem>
377       <para>
378        Throw an error if an escape character is the last character in
379        a <literal>LIKE</> pattern (i.e., it has nothing to escape) (Tom)
380       </para>
381
382       <para>
383        Previously, such an escape character was silently ignored,
384        thus possibly masking application logic errors.
385       </para>
386      </listitem>
387
388      <listitem>
389       <para>
390        Remove <literal>~=~</> and <literal>~&lt;&gt;~</> operators
391        formerly used for <literal>LIKE</> index comparisons (Tom)
392       </para>
393
394       <para>
395        Pattern indexes now use the regular equality operator.
396       </para>
397      </listitem>
398
399      <listitem>
400       <para>
401        <function>xpath()</> now passes its arguments to <application>libxml</>
402        without any changes (Andrew)
403       </para>
404
405       <para>
406        This means that the XML argument must be a well-formed XML document.
407        The previous coding attempted to allow XML fragments, but it did not
408        work well.
409       </para>
410      </listitem>
411
412      <listitem>
413       <para>
414        Make <function>xmlelement()</> format attribute values just like
415        content values (Peter)
416       </para>
417
418       <para>
419        Previously, attribute values were formatted according to the
420        normal SQL output behavior, which is sometimes at odds with
421        XML rules.
422       </para>
423      </listitem>
424
425      <listitem>
426       <para>
427        Rewrite memory management for <application>libxml</>-using functions
428        (Tom)
429       </para>
430
431       <para>
432        This change should avoid some compatibility problems with use of
433        <application>libxml</> in PL/Perl and other add-on code.
434       </para>
435      </listitem>
436
437      <listitem>
438       <para>
439        Adopt a faster algorithm for hash functions (Kenneth Marshall,
440        based on work of Bob Jenkins)
441       </para>
442
443       <para>
444        Many of the built-in hash functions now deliver different results on
445        little-endian and big-endian platforms.
446       </para>
447      </listitem>
448
449     </itemizedlist>
450
451     <sect4>
452      <title>Temporal Functions and Operators</title>
453
454      <itemizedlist>
455
456       <listitem>
457        <para>
458         <varname>DateStyle</> no longer controls <type>interval</> output
459         formatting; instead there is a new variable <varname>IntervalStyle</>
460         (Ron Mayer)
461        </para>
462       </listitem>
463
464       <listitem>
465        <para>
466         Improve consistency of handling of fractional seconds in
467         <type>timestamp</> and <type>interval</> output (Ron Mayer)
468        </para>
469
470        <para>
471         This may result in displaying a different number of fractional
472         digits than before, or rounding instead of truncating.
473        </para>
474       </listitem>
475
476       <listitem>
477        <para>
478         Make <function>to_char()</>'s localized month/day names depend
479         on <varname>LC_TIME</>, not <varname>LC_MESSAGES</> (Euler
480         Taveira de Oliveira)
481        </para>
482       </listitem>
483
484       <listitem>
485        <para>
486         Cause <function>to_date()</> and <function>to_timestamp()</>
487         to more consistently report errors for invalid input (Brendan
488         Jurd)
489        </para>
490
491        <para>
492         Previous versions would often ignore or silently misread input
493         that did not match the format string.  Such cases will now
494         result in an error.
495        </para>
496       </listitem>
497
498       <listitem>
499        <para>
500         Fix <function>to_timestamp()</> to not require upper/lower case
501         matching for meridian (<literal>AM</>/<literal>PM</>) and era
502         (<literal>BC</>/<literal>AD</>) format designations  (Brendan
503         Jurd)
504        </para>
505
506        <para>
507         For example, input value <literal>ad</> now matches the format
508         string <literal>AD</>.
509        </para>
510       </listitem>
511
512      </itemizedlist>
513
514     </sect4>
515
516    </sect3>
517
518   </sect2>
519
520   <sect2>
521    <title>Changes</title>
522
523    <para>
524     Below you will find a detailed account of the changes between
525     <productname>PostgreSQL</productname> 8.4 and the previous major
526     release.
527    </para>
528
529    <sect3>
530     <title>Performance</title>
531     <itemizedlist>
532
533      <listitem>
534       <para>
535        Improve optimizer statistics calculations (Jan Urbanski, Tom)
536       </para>
537
538       <para>
539        In particular, estimates for full-text-search operators are
540        greatly improved.
541       </para>
542      </listitem>
543
544      <listitem>
545       <para>
546        Allow <command>SELECT DISTINCT</> and
547        <literal>UNION</>/<literal>INTERSECT</>/<literal>EXCEPT</> to
548        use hashing (Tom)
549       </para>
550
551       <para>
552        This means that these types of queries no longer automatically
553        produce sorted output.
554       </para>
555      </listitem>
556
557      <listitem>
558       <para>
559        Create explicit concepts of semi-joins and anti-joins (Tom)
560       </para>
561
562       <para>
563        This work formalizes our previous ad-hoc treatment of <literal>IN
564        (SELECT ...)</> clauses, and extends it to <literal>EXISTS</> and
565        <literal>NOT EXISTS</> clauses.  It should result in significantly
566        better planning of <literal>EXISTS</> and <literal>NOT EXISTS</>
567        queries.  In general, logically equivalent <literal>IN</> and
568        <literal>EXISTS</> clauses should now have similar performance,
569        whereas previously <literal>IN</> often won.
570       </para>
571      </listitem>
572
573      <listitem>
574       <para>
575        Improve optimization of sub-selects beneath outer joins (Tom)
576       </para>
577
578       <para>
579        Formerly, a sub-select or view could not be optimized very well if it
580        appeared within the nullable side of an outer join and contained
581        non-strict expressions (for instance, constants) in its result list.
582       </para>
583      </listitem>
584
585      <listitem>
586       <para>
587        Improve the performance of <function>text_position()</> and
588        related functions by using Boyer-Moore-Horspool searching (David
589        Rowley)
590       </para>
591
592       <para>
593        This is particularly helpful for long search patterns.
594       </para>
595      </listitem>
596
597      <listitem>
598       <para>
599        Reduce I/O load of writing the statistics collection file
600        by writing the file only when requested (Martin Pihlak)
601       </para>
602      </listitem>
603
604      <listitem>
605       <para>
606        Improve performance for bulk inserts (Robert Haas, Simon)
607       </para>
608      </listitem>
609
610      <listitem>
611       <para>
612        Increase the default value of <varname>default_statistics_target</>
613        from <literal>10</> to <literal>100</> (Greg Sabino Mullane,
614        Tom)
615       </para>
616
617       <para>
618        The maximum value was also increased from <literal>1000</> to
619        <literal>10000</>.
620       </para>
621      </listitem>
622
623      <listitem>
624       <para>
625        Perform <varname>constraint_exclusion</> checking by default
626        in queries involving inheritance or <literal>UNION ALL</> (Tom)
627       </para>
628
629       <para>
630        A new <varname>constraint_exclusion</> setting,
631        <literal>partition</>, was added to specify this behavior.
632       </para>
633      </listitem>
634
635      <listitem>
636       <para>
637        Allow I/O read-ahead for bitmap index scans (Greg Stark)
638       </para>
639
640       <para>
641        The amount of read-ahead is controlled by
642        <varname>effective_io_concurrency</>.  This feature is available only
643        if the kernel has <function>posix_fadvise()</> support.
644       </para>
645      </listitem>
646
647      <listitem>
648       <para>
649        Inline simple set-returning <acronym>SQL</> functions in
650        <literal>FROM</> clauses (Richard Rowell)
651       </para>
652      </listitem>
653
654      <listitem>
655       <para>
656        Improve performance of multi-batch hash joins by providing a special
657        case for join key values that are especially common in the outer
658        relation (Bryce Cutt, Ramon Lawrence)
659       </para>
660      </listitem>
661
662      <listitem>
663       <para>
664        Reduce volume of temporary data in multi-batch hash joins
665        by suppressing <quote>physical tlist</> optimization (Michael
666        Henderson, Ramon Lawrence)
667       </para>
668      </listitem>
669
670      <listitem>
671       <para>
672        Avoid waiting for idle-in-transaction sessions during
673        <command>CREATE INDEX CONCURRENTLY</> (Simon)
674       </para>
675      </listitem>
676
677      <listitem>
678       <para>
679        Improve performance of shared cache invalidation (Tom)
680       </para>
681      </listitem>
682
683     </itemizedlist>
684
685    </sect3>
686
687    <sect3>
688     <title>Server</title>
689
690     <sect4>
691      <title>Settings</title>
692
693      <itemizedlist>
694
695       <listitem>
696        <para>
697         Convert many <filename>postgresql.conf</> settings to enumerated
698         values so that <literal>pg_settings</> can display the valid
699         values (Magnus)
700        </para>
701       </listitem>
702
703       <listitem>
704        <para>
705         Add <varname>cursor_tuple_fraction</> parameter to control the
706         fraction of a cursor's rows that the planner assumes will be
707         fetched (Robert Hell)
708        </para>
709       </listitem>
710
711       <listitem>
712        <para>
713         Allow underscores in the names of custom variable
714         classes in <filename>postgresql.conf</> (Tom)
715        </para>
716       </listitem>
717
718      </itemizedlist>
719
720     </sect4>
721
722     <sect4>
723      <title>Authentication and security</title>
724      <itemizedlist>
725
726       <listitem>
727        <para>
728         Remove support for the (insecure) <literal>crypt</> authentication method
729         (Magnus)
730        </para>
731
732        <para>
733         This effectively obsoletes pre-<productname>PostgreSQL</> 7.2 client
734         libraries, as there is no longer any non-plaintext password method that
735         they can use.
736        </para>
737       </listitem>
738
739       <listitem>
740        <para>
741         Support regular expressions in <filename>pg_ident.conf</>
742         (Magnus)
743        </para>
744       </listitem>
745
746       <listitem>
747        <para>
748         Allow <productname>Kerberos</>/<acronym>GSSAPI</> parameters
749         to be changed without restarting the postmaster (Magnus)
750        </para>
751       </listitem>
752
753       <listitem>
754        <para>
755         Support <acronym>SSL</> certificate chains in server certificate
756         file (Andrew Gierth)
757        </para>
758
759        <para>
760         Including the full certificate chain makes the client able
761         to verify the certificate without having all intermediate CA
762         certificates present in the local store, which is often the case for
763         commercial CAs.
764        </para>
765       </listitem>
766
767       <listitem>
768        <para>
769         Report appropriate error message for combination of <literal>MD5</>
770         authentication and <varname>db_user_namespace</> enabled (Bruce)
771        </para>
772       </listitem>
773      </itemizedlist>
774
775     </sect4>
776
777     <sect4 id="release-8-4-pg-hba-conf">
778      <title><filename>pg_hba.conf</></title>
779      <itemizedlist>
780
781       <listitem>
782        <para>
783         Change all authentication options to use <literal>name=value</>
784         syntax (Magnus)
785        </para>
786
787        <para>
788         This makes incompatible changes to the <literal>ldap</>,
789         <literal>pam</> and <literal>ident</> authentication methods. All
790         <filename>pg_hba.conf</> entries with these methods need to be
791         rewritten using the new format.
792        </para>
793       </listitem>
794
795       <listitem>
796        <para>
797         Remove the <literal>ident sameuser</> option, instead making that
798         behavior the default if no usermap is specified (Magnus)
799        </para>
800       </listitem>
801
802       <listitem>
803        <para>
804         Allow a usermap parameter for all external authentication methods
805         (Magnus)
806        </para>
807
808        <para>
809         Previously a usermap was only supported for <literal>ident</>
810         authentication.
811        </para>
812       </listitem>
813
814       <listitem>
815        <para>
816         Add <literal>clientcert</> option to control requesting of a
817         client certificate (Magnus)
818        </para>
819
820        <para>
821         Previously this was controlled by the presence of a root
822         certificate file in the server's data directory.
823        </para>
824       </listitem>
825
826       <listitem>
827        <para>
828         Add <literal>cert</> authentication method to allow
829         <emphasis>user</> authentication via <acronym>SSL</> certificates
830         (Magnus)
831        </para>
832
833        <para>
834         Previously <acronym>SSL</> certificates could only verify that
835         the client had access to a certificate, not authenticate a
836         user.
837        </para>
838       </listitem>
839
840       <listitem>
841        <para>
842         Allow <literal>krb5</>, <literal>gssapi</> and <literal>sspi</>
843         realm and <literal>krb5</> host settings to be specified in
844         <filename>pg_hba.conf</> (Magnus)
845        </para>
846
847        <para>
848         These override the settings in <filename>postgresql.conf</>.
849        </para>
850       </listitem>
851
852       <listitem>
853        <para>
854         Add <varname>include_realm</> parameter for <literal>krb5</>,
855         <literal>gssapi</>, and <literal>sspi</> methods (Magnus)
856        </para>
857
858        <para>
859         This allows identical usernames from different realms to be
860         authenticated as different database users using usermaps.
861        </para>
862       </listitem>
863
864       <listitem>
865        <para>
866         Parse <filename>pg_hba.conf</> fully when it is loaded,
867         so that errors are reported immediately (Magnus)
868        </para>
869
870        <para>
871         Previously, most errors in the file wouldn't be detected until clients
872         tried to connect, so an erroneous file could render the system
873         unusable.  With the new behavior, if an error is detected during
874         reload then the bad file is rejected and the postmaster continues
875         to use its old copy.
876        </para>
877       </listitem>
878
879       <listitem>
880        <para>
881         Show all parsing errors in <filename>pg_hba.conf</> instead of
882         aborting after the first one (Selena Deckelmann)
883        </para>
884       </listitem>
885
886       <listitem>
887        <para>
888         Support <literal>ident</> authentication over Unix-domain sockets
889         on <productname>Solaris</> (Garick Hamlin)
890        </para>
891       </listitem>
892
893      </itemizedlist>
894
895     </sect4>
896
897     <sect4>
898      <title>Continuous Archiving</title>
899      <itemizedlist>
900
901       <listitem>
902        <para>
903         Provide an option to <function>pg_start_backup()</> to force its
904         implied checkpoint to finish as quickly as possible (Tom)
905        </para>
906
907        <para>
908         The default behavior avoids excess I/O consumption, but that is
909         pointless if no concurrent query activity is going on.
910        </para>
911       </listitem>
912
913       <listitem>
914        <para>
915         Make <function>pg_stop_backup()</> wait for modified <acronym>WAL</>
916         files to be archived (Simon)
917        </para>
918
919        <para>
920         This guarantees that the backup is valid at the time
921         <function>pg_stop_backup()</> completes.
922        </para>
923       </listitem>
924
925       <listitem>
926        <para>
927         Delay <quote>smart</> shutdown while a continuous archiving base backup
928         is in progress (Laurenz Albe)
929        </para>
930       </listitem>
931
932       <listitem>
933        <para>
934         Cancel a continuous archiving base backup if <quote>fast</> shutdown
935         is requested (Laurenz Albe)
936        </para>
937       </listitem>
938
939       <listitem>
940        <para>
941         Allow <filename>recovery.conf</> boolean variables to take the
942         same range of string values as <filename>postgresql.conf</>
943         boolean variables
944         (Bruce)
945        </para>
946       </listitem>
947
948      </itemizedlist>
949
950     </sect4>
951
952     <sect4>
953      <title>Monitoring</title>
954      <itemizedlist>
955
956       <listitem>
957        <para>
958         Add <function>pg_conf_load_time()</> to report when
959         the <productname>PostgreSQL</> configuration files were last loaded
960         (George Gensure)
961        </para>
962       </listitem>
963
964       <listitem>
965        <para>
966         Add <function>pg_terminate_backend()</> to safely terminate a
967         backend (the <literal>SIGTERM</> signal works also) (Tom, Bruce)
968        </para>
969
970        <para>
971         While it's always been possible to <literal>SIGTERM</> a single
972         backend, this was previously considered unsupported; and testing
973         of the case found some bugs that are now fixed.
974        </para>
975       </listitem>
976
977       <listitem>
978        <para>
979         Add ability to track user-defined functions' call counts and
980         runtimes (Martin Pihlak)
981        </para>
982
983        <para>
984         Function statistics appear in a new system view,
985         <literal>pg_stat_user_functions</>.  Tracking is controlled
986         by the new parameter <varname>track_functions</>.
987        </para>
988       </listitem>
989
990       <listitem>
991        <para>
992         Allow specification of the maximum query string size in
993         <literal>pg_stat_activity</> via new
994         <varname>track_activity_query_size</> parameter (Thomas Lee)
995        </para>
996       </listitem>
997
998       <listitem>
999        <para>
1000         Increase the maximum line length sent to <application>syslog</>, in
1001         hopes of improving performance (Tom)
1002        </para>
1003       </listitem>
1004
1005       <listitem>
1006        <para>
1007         Add read-only configuration variables <varname>segment_size</>,
1008         <varname>wal_block_size</>, and <varname>wal_segment_size</>
1009         (Bernd Helmle)
1010        </para>
1011       </listitem>
1012
1013       <listitem>
1014        <para>
1015         When reporting a deadlock, report the text of all queries involved
1016         in the deadlock to the server log  (Itagaki Takahiro)
1017        </para>
1018       </listitem>
1019
1020       <listitem>
1021        <para>
1022         Add <function>pg_stat_get_activity(pid)</> function to return
1023         information about a specific process id (Magnus)
1024        </para>
1025       </listitem>
1026
1027       <listitem>
1028        <para>
1029         Allow the location of the server's statistics file to be specified
1030         via <varname>stats_temp_directory</> (Magnus)
1031        </para>
1032
1033        <para>
1034         This allows the statistics file to be placed in a
1035         <acronym>RAM</>-resident directory to reduce I/O requirements.
1036         On startup/shutdown, the file is copied to its traditional location
1037         (<literal>$PGDATA/global/</>) so it is preserved across restarts.
1038        </para>
1039       </listitem>
1040
1041      </itemizedlist>
1042
1043     </sect4>
1044
1045    </sect3>
1046
1047    <sect3>
1048     <title>Queries</title>
1049     <itemizedlist>
1050
1051      <listitem>
1052       <para>
1053        Add support for <literal>WINDOW</> functions (Hitoshi Harada)
1054       </para>
1055      </listitem>
1056
1057      <listitem>
1058       <para>
1059        Add support for <literal>WITH</> clauses (CTEs), including <literal>WITH
1060        RECURSIVE</> (Yoshiyuki Asaba, Tatsuo Ishii, Tom)
1061       </para>
1062      </listitem>
1063
1064      <listitem>
1065       <para>
1066        Add <command>TABLE</> command (Peter)
1067       </para>
1068
1069       <para>
1070        <literal>TABLE tablename</> is a SQL standard short-hand for
1071        <literal>SELECT * FROM tablename</>.
1072       </para>
1073      </listitem>
1074
1075      <listitem>
1076       <para>
1077        Allow <literal>AS</> to be optional when specifying a
1078        <command>SELECT</> (or <literal>RETURNING</>) column output
1079        label (Hiroshi Saito)
1080       </para>
1081
1082       <para>
1083        This works so long as the column label is not any
1084        <productname>PostgreSQL</> keyword; otherwise <literal>AS</> is still
1085        needed.
1086       </para>
1087      </listitem>
1088
1089      <listitem>
1090       <para>
1091        Support set-returning functions in <command>SELECT</> result lists
1092        even for functions that return their result via a tuplestore (Tom)
1093       </para>
1094
1095       <para>
1096        In particular, this means that functions written in PL/PgSQL
1097        and other PL languages can now be called this way.
1098       </para>
1099      </listitem>
1100
1101      <listitem>
1102       <para>
1103        Support set-returning functions in the output of aggregation
1104        and grouping queries (Tom)
1105       </para>
1106      </listitem>
1107
1108      <listitem>
1109       <para>
1110        Allow <command>SELECT FOR UPDATE</>/<literal>SHARE</> to work
1111        on inheritance trees (Tom)
1112       </para>
1113      </listitem>
1114
1115      <listitem>
1116       <para>
1117        Add infrastructure for <acronym>SQL/MED</> (Martin Pihlak,
1118        Peter)
1119       </para>
1120
1121       <para>
1122        There are no remote or external <acronym>SQL/MED</> capabilities
1123        yet, but this change provides a standardized and future-proof
1124        system for managing connection information for modules like
1125        <filename>dblink</> and <filename>plproxy</>.
1126       </para>
1127      </listitem>
1128
1129      <listitem>
1130       <para>
1131        Invalidate cached plans when referenced schemas, functions, operators,
1132        or operator classes are modified (Martin Pihlak, Tom)
1133       </para>
1134
1135       <para>
1136        This improves the system's ability to respond to on-the-fly
1137        DDL changes.
1138       </para>
1139      </listitem>
1140      <listitem>
1141       <para>
1142        Allow comparison of composite types and allow arrays of
1143        anonymous composite types (Tom)
1144       </para>
1145
1146       <para>
1147        This allows constructs such as
1148        <literal>row(1, 1.1) = any (array[row(7, 7.7), row(1, 1.0)])</>.
1149        This is particularly useful in recursive queries.
1150       </para>
1151      </listitem>
1152
1153      <listitem>
1154       <para>
1155        Add support for Unicode string literal and identifier specifications
1156        using code points, e.g. <literal>U&amp;'d\0061t\+000061'</>
1157        (Peter)
1158       </para>
1159      </listitem>
1160
1161      <listitem>
1162       <para>
1163        Reject <literal>\000</> in string literals and <command>COPY</> data
1164        (Tom)
1165       </para>
1166
1167       <para>
1168        Previously, this was accepted but had the effect of terminating
1169        the string contents.
1170       </para>
1171      </listitem>
1172
1173      <listitem>
1174       <para>
1175        Improve the parser's ability to report error locations (Tom)
1176       </para>
1177
1178       <para>
1179        An error location is now reported for many semantic errors,
1180        such as mismatched datatypes, that previously could not be localized.
1181       </para>
1182      </listitem>
1183
1184     </itemizedlist>
1185
1186     <sect4>
1187      <title><command>TRUNCATE</></title>
1188      <itemizedlist>
1189
1190       <listitem>
1191        <para>
1192         Support statement-level <literal>ON TRUNCATE</> triggers (Simon)
1193        </para>
1194       </listitem>
1195
1196       <listitem>
1197        <para>
1198         Add <literal>RESTART</>/<literal>CONTINUE IDENTITY</> options
1199         for <command>TRUNCATE TABLE</>
1200         (Zoltan Boszormenyi)
1201        </para>
1202
1203        <para>
1204         The start value of a sequence can be changed by <command>ALTER
1205         SEQUENCE START WITH</>.
1206        </para>
1207       </listitem>
1208
1209       <listitem>
1210        <para>
1211         Allow <command>TRUNCATE tab1, tab1</> to succeed (Bruce)
1212        </para>
1213       </listitem>
1214
1215       <listitem>
1216        <para>
1217         Add a separate <command>TRUNCATE</> permission (Robert Haas)
1218        </para>
1219       </listitem>
1220
1221      </itemizedlist>
1222
1223     </sect4>
1224
1225     <sect4>
1226      <title><command>EXPLAIN</></title>
1227      <itemizedlist>
1228
1229       <listitem>
1230        <para>
1231         Make <command>EXPLAIN VERBOSE</> show the output columns of each
1232         plan node (Tom)
1233        </para>
1234
1235        <para>
1236         Previously <command>EXPLAIN VERBOSE</> output an internal
1237         representation of the query plan.  (That behavior is now
1238         available via <varname>debug_print_plan</>.)
1239        </para>
1240       </listitem>
1241
1242       <listitem>
1243        <para>
1244         Make <command>EXPLAIN</> identify subplans and initplans with
1245         individual labels (Tom)
1246        </para>
1247       </listitem>
1248
1249       <listitem>
1250        <para>
1251         Make <command>EXPLAIN</> honor <varname>debug_print_plan</> (Tom)
1252        </para>
1253       </listitem>
1254
1255       <listitem>
1256        <para>
1257         Allow <command>EXPLAIN</> on <command>CREATE TABLE AS</> (Peter)
1258        </para>
1259       </listitem>
1260
1261      </itemizedlist>
1262
1263     </sect4>
1264
1265     <sect4>
1266      <title><literal>LIMIT</>/<literal>OFFSET</></title>
1267      <itemizedlist>
1268
1269       <listitem>
1270        <para>
1271         Allow sub-selects in <literal>LIMIT</> and <literal>OFFSET</> (Tom)
1272        </para>
1273       </listitem>
1274
1275       <listitem>
1276        <para>
1277         Add <acronym>SQL</>-standard syntax for
1278         <literal>LIMIT</>/<literal>OFFSET</> capabilities (Peter)
1279        </para>
1280
1281        <para>
1282         To wit,
1283         <literal>OFFSET num {ROW|ROWS} FETCH {FIRST|NEXT} [num] {ROW|ROWS}
1284         ONLY</>.
1285        </para>
1286       </listitem>
1287
1288      </itemizedlist>
1289
1290     </sect4>
1291
1292    </sect3>
1293
1294    <sect3>
1295     <title>Object Manipulation</title>
1296     <itemizedlist>
1297
1298      <listitem>
1299       <para>
1300        Add support for column-level privileges (Stephen Frost, KaiGai
1301        Kohei)
1302       </para>
1303      </listitem>
1304
1305      <listitem>
1306       <para>
1307        Refactor multi-object <command>DROP</> operations to reduce the
1308        need for <literal>CASCADE</> (Alex Hunsaker)
1309       </para>
1310
1311       <para>
1312        For example, if table <literal>B</> has a dependency on table
1313        <literal>A</>, the command <literal>DROP TABLE A, B</> no longer
1314        requires the <literal>CASCADE</> option.
1315       </para>
1316      </listitem>
1317
1318      <listitem>
1319       <para>
1320        Fix various problems with concurrent <command>DROP</> commands
1321        by ensuring that locks are taken before we begin to drop dependencies
1322        of an object (Tom)
1323       </para>
1324      </listitem>
1325
1326      <listitem>
1327       <para>
1328        Improve reporting of dependencies during <command>DROP</>
1329        commands (Tom)
1330       </para>
1331      </listitem>
1332
1333      <listitem>
1334       <para>
1335        Add <literal>WITH [NO] DATA</> clause to <command>CREATE TABLE
1336        AS</>, per the <acronym>SQL</> standard (Peter, Tom)
1337       </para>
1338      </listitem>
1339
1340      <listitem>
1341       <para>
1342        Add support for user-defined I/O conversion casts (Heikki)
1343       </para>
1344      </listitem>
1345
1346      <listitem>
1347       <para>
1348        Allow <command>CREATE AGGREGATE</> to use an <type>internal</>
1349        transition datatype (Tom)
1350       </para>
1351      </listitem>
1352
1353      <listitem>
1354       <para>
1355        Add <literal>LIKE</> clause to <command>CREATE TYPE</> (Tom)
1356       </para>
1357
1358       <para>
1359        This simplifies creation of data types that use the same internal
1360        representation as an existing type.
1361       </para>
1362      </listitem>
1363
1364      <listitem>
1365       <para>
1366        Allow specification of the type category and <quote>preferred</>
1367        status for user-defined base types (Tom)
1368       </para>
1369
1370       <para>
1371        This allows more control over the coercion behavior of user-defined
1372        types.
1373       </para>
1374      </listitem>
1375
1376      <listitem>
1377       <para>
1378        Allow <command>CREATE OR REPLACE VIEW</> to add columns to the
1379        end of a view (Robert Haas)
1380       </para>
1381      </listitem>
1382
1383     </itemizedlist>
1384
1385     <sect4>
1386      <title><command>ALTER</></title>
1387      <itemizedlist>
1388
1389       <listitem>
1390        <para>
1391         Add <command>ALTER TYPE RENAME</> (Petr Jelinek)
1392        </para>
1393       </listitem>
1394
1395       <listitem>
1396        <para>
1397         Add <command>ALTER SEQUENCE ... RESTART</> (with no parameter) to
1398         reset a sequence to its initial value (Zoltan Boszormenyi)
1399        </para>
1400       </listitem>
1401
1402       <listitem>
1403        <para>
1404         Modify the <command>ALTER TABLE</> syntax to allow all reasonable
1405         combinations for tables, indexes, sequences, and views (Tom)
1406        </para>
1407
1408        <para>
1409         This change allows the following new syntaxes:
1410
1411         <itemizedlist>
1412          <listitem>
1413           <para>
1414            <command>ALTER SEQUENCE OWNER TO</>
1415           </para>
1416          </listitem>
1417          <listitem>
1418           <para>
1419            <command>ALTER VIEW ALTER COLUMN SET/DROP DEFAULT</>
1420           </para>
1421          </listitem>
1422          <listitem>
1423           <para>
1424            <command>ALTER VIEW OWNER TO</>
1425           </para>
1426          </listitem>
1427          <listitem>
1428           <para>
1429            <command>ALTER VIEW SET SCHEMA</>
1430           </para>
1431          </listitem>
1432         </itemizedlist>
1433
1434         There is no actual new functionality here, but formerly
1435         you had to say <command>ALTER TABLE</> to do these things,
1436         which was confusing.
1437        </para>
1438       </listitem>
1439
1440       <listitem>
1441        <para>
1442         Add support for the syntax <command>ALTER TABLE ... ALTER COLUMN
1443         ... SET DATA TYPE</> (Peter)
1444        </para>
1445
1446        <para>
1447         This is <acronym>SQL</>-standard syntax for functionality that
1448         was already supported.
1449        </para>
1450       </listitem>
1451
1452       <listitem>
1453        <para>
1454         Make <command>ALTER TABLE SET WITHOUT OIDS</> rewrite the table
1455         to physically remove <type>OID</> values (Tom)
1456        </para>
1457
1458        <para>
1459         Also, add <command>ALTER TABLE SET WITH OIDS</> to rewrite the
1460         table to add <type>OID</>s.
1461        </para>
1462       </listitem>
1463
1464      </itemizedlist>
1465
1466     </sect4>
1467
1468     <sect4>
1469      <title>Database Manipulation</title>
1470      <itemizedlist>
1471
1472       <listitem>
1473        <para>
1474         Improve reporting of
1475         <command>CREATE</>/<command>DROP</>/<command>RENAME DATABASE</>
1476         failure when uncommitted prepared transactions are the cause
1477         (Tom)
1478        </para>
1479       </listitem>
1480
1481       <listitem>
1482        <para>
1483         Make <varname>LC_COLLATE</> and <varname>LC_CTYPE</> into
1484         per-database settings (Radek Strnad, Heikki)
1485        </para>
1486
1487        <para>
1488         This makes collation similar to encoding, which was always
1489         configurable per database.
1490        </para>
1491       </listitem>
1492
1493       <listitem>
1494        <para>
1495         Improve checks that the database encoding, collation
1496         (<varname>LC_COLLATE</>), and character classes
1497         (<varname>LC_CTYPE</>) match (Heikki, Tom)
1498        </para>
1499
1500        <para>
1501         Note in particular that a new database's encoding and locale
1502         settings can be changed only when copying from <literal>template0</>.
1503         This prevents possibly copying data that doesn't match the settings.
1504        </para>
1505       </listitem>
1506
1507       <listitem>
1508        <para>
1509         Add <command>ALTER DATABASE SET TABLESPACE</> to move a database
1510         to a new tablespace (Guillaume Lelarge, Bernd Helmle)
1511        </para>
1512       </listitem>
1513
1514      </itemizedlist>
1515
1516     </sect4>
1517
1518    </sect3>
1519
1520    <sect3>
1521     <title>Utility Operations</title>
1522
1523     <itemizedlist>
1524
1525      <listitem>
1526       <para>
1527        Add a <literal>VERBOSE</> option to the <command>CLUSTER</> command and
1528        <application>clusterdb</> (Jim Cox)
1529       </para>
1530      </listitem>
1531
1532      <listitem>
1533       <para>
1534        Decrease memory requirements for recording pending trigger
1535        events (Tom)
1536       </para>
1537      </listitem>
1538
1539     </itemizedlist>
1540
1541     <sect4>
1542      <title>Indexes</title>
1543      <itemizedlist>
1544
1545       <listitem>
1546        <para>
1547         Dramatically improve the speed of building and accessing hash
1548         indexes (Tom Raney, Shreya Bhargava)
1549        </para>
1550
1551        <para>
1552         This allows hash indexes to be sometimes faster than btree
1553         indexes.  However, hash indexes are still not crash-safe.
1554        </para>
1555       </listitem>
1556
1557       <listitem>
1558        <para>
1559         Make hash indexes store only the hash code, not the full value of
1560         the indexed column (Xiao Meng)
1561        </para>
1562
1563        <para>
1564         This greatly reduces the size of hash indexes for long indexed
1565         values, improving performance.
1566        </para>
1567       </listitem>
1568
1569       <listitem>
1570        <para>
1571         Implement fast update option for GIN indexes (Teodor, Oleg)
1572        </para>
1573
1574        <para>
1575         This option greatly improves update speed at a small penalty in search
1576         speed.
1577        </para>
1578       </listitem>
1579
1580       <listitem>
1581        <para>
1582         <literal>xxx_pattern_ops</> indexes can now be used for simple
1583         equality comparisons, not only for <literal>LIKE</> (Tom)
1584        </para>
1585       </listitem>
1586
1587      </itemizedlist>
1588
1589     </sect4>
1590
1591     <sect4>
1592      <title>Full Text Indexes</title>
1593      <itemizedlist>
1594
1595       <listitem>
1596        <para>
1597         Remove the requirement to use <literal>@@@</> when doing
1598         <acronym>GIN</> weighted lookups on full text indexes (Tom, Teodor)
1599        </para>
1600
1601        <para>
1602         The normal <literal>@@</> text search operator can be used
1603         instead.
1604        </para>
1605       </listitem>
1606
1607       <listitem>
1608        <para>
1609         Add an optimizer selectivity function for <literal>@@</> text
1610         search operations (Jan Urbanski)
1611        </para>
1612       </listitem>
1613
1614       <listitem>
1615        <para>
1616         Allow prefix matching in full text searches (Teodor Sigaev,
1617         Oleg Bartunov)
1618        </para>
1619       </listitem>
1620
1621       <listitem>
1622        <para>
1623         Support multi-column <acronym>GIN</> indexes (Teodor Sigaev)
1624        </para>
1625       </listitem>
1626
1627       <listitem>
1628        <para>
1629         Improve support for Nepali language and Devanagari alphabet (Teodor)
1630        </para>
1631       </listitem>
1632
1633      </itemizedlist>
1634
1635     </sect4>
1636
1637     <sect4>
1638      <title><command>VACUUM</></title>
1639      <itemizedlist>
1640
1641       <listitem>
1642        <para>
1643         Track free space in separate per-relation <quote>fork</> files (Heikki)
1644        </para>
1645
1646        <para>
1647         Free space discovered by <command>VACUUM</> is now recorded in
1648         <filename>*_fsm</> files, rather than in a fixed-sized shared memory
1649         area.  The <varname>max_fsm_pages</> and <varname>max_fsm_relations</>
1650         settings have been removed, greatly simplifying administration of
1651         free space management.
1652        </para>
1653       </listitem>
1654
1655       <listitem>
1656        <para>
1657         Add a visibility map to track pages that do not require
1658         vacuuming (Heikki)
1659        </para>
1660
1661        <para>
1662         This allows <command>VACUUM</> to avoid scanning all of
1663         a table when only a portion of the table needs vacuuming.
1664         The visibility map is stored in per-relation <quote>fork</> files.
1665        </para>
1666       </listitem>
1667
1668       <listitem>
1669        <para>
1670         Add <varname>vacuum_freeze_table_age</> parameter to control
1671         when <command>VACUUM</> should ignore the visibility map and
1672         do a full table scan to freeze tuples (Heikki)
1673        </para>
1674       </listitem>
1675
1676       <listitem>
1677        <para>
1678         Track transaction snapshots more carefully (Alvaro)
1679        </para>
1680
1681        <para>
1682         This improves <command>VACUUM</>'s ability to reclaim space
1683         in the presence of long-running transactions.
1684        </para>
1685       </listitem>
1686
1687       <listitem>
1688        <para>
1689         Add ability to specify per-relation autovacuum and <acronym>TOAST</>
1690         parameters in <command>CREATE TABLE</> (Alvaro, Euler Taveira de
1691         Oliveira)
1692        </para>
1693
1694        <para>
1695         Autovacuum options used to be stored in a system table.
1696        </para>
1697       </listitem>
1698
1699       <listitem>
1700        <para>
1701         Add <literal>--freeze</> option to <application>vacuumdb</>
1702         (Bruce)
1703        </para>
1704       </listitem>
1705
1706      </itemizedlist>
1707
1708     </sect4>
1709
1710    </sect3>
1711
1712    <sect3>
1713     <title>Data Types</title>
1714     <itemizedlist>
1715
1716      <listitem>
1717       <para>
1718        Add a <literal>CaseSensitive</> option for text search synonym
1719        dictionaries (Simon)
1720       </para>
1721      </listitem>
1722
1723      <listitem>
1724       <para>
1725        Improve the precision of <type>NUMERIC</> division (Tom)
1726       </para>
1727      </listitem>
1728
1729      <listitem>
1730       <para>
1731        Add basic arithmetic operators for <type>int2</> with <type>int8</>
1732        (Tom)
1733       </para>
1734
1735       <para>
1736        This eliminates the need for explicit casting in some situations.
1737       </para>
1738      </listitem>
1739
1740      <listitem>
1741       <para>
1742        Allow <type>UUID</> input to accept an optional hyphen after
1743        every fourth digit (Robert Haas)
1744       </para>
1745      </listitem>
1746
1747      <listitem>
1748       <para>
1749        Allow <literal>on</>/<literal>off</> as input for the boolean data type
1750        (Itagaki Takahiro)
1751       </para>
1752      </listitem>
1753
1754      <listitem>
1755       <para>
1756        Allow spaces around <literal>NaN</> in the input string for
1757        type <type>numeric</> (Sam Mason)
1758       </para>
1759      </listitem>
1760
1761     </itemizedlist>
1762
1763     <sect4>
1764      <title>Temporal Data Types</title>
1765      <itemizedlist>
1766
1767       <listitem>
1768        <para>
1769         Reject year <literal>0 BC</> and years <literal>000</> and
1770         <literal>0000</> (Tom)
1771        </para>
1772
1773        <para>
1774         Previously these were interpreted as <literal>1 BC</>.
1775         (Note: years <literal>0</> and <literal>00</> are still assumed to be
1776         the year 2000.)
1777        </para>
1778       </listitem>
1779
1780       <listitem>
1781        <para>
1782         Include <literal>SGT</> (Singapore time) in the default list of
1783         known time zone abbreviations (Tom)
1784        </para>
1785       </listitem>
1786
1787       <listitem>
1788        <para>
1789         Support <literal>infinity</> and <literal>-infinity</> as
1790         values of type <type>date</> (Tom)
1791        </para>
1792       </listitem>
1793
1794       <listitem>
1795        <para>
1796         Make parsing of <type>interval</> literals more standard-compliant (Tom)
1797        </para>
1798
1799        <para>
1800         For example, <literal>INTERVAL '1' YEAR</> now does what it's
1801         supposed to.
1802        </para>
1803       </listitem>
1804
1805       <listitem>
1806        <para>
1807         Allow <type>interval</> fractional-seconds precision to be specified
1808         after the <literal>second</> keyword, for <acronym>SQL</> standard
1809         compliance (Tom)
1810        </para>
1811
1812        <para>
1813         Formerly the precision had to be specified after the keyword
1814         <type>interval</>.  (For backwards compatibility, this syntax is still
1815         supported, though deprecated.)  Data type definitions will now be
1816         output using the standard format.
1817        </para>
1818       </listitem>
1819
1820       <listitem>
1821        <para>
1822         Support the <acronym>IS0 8601</> <type>interval</> syntax (Ron
1823         Mayer, Kevin Grittner)
1824        </para>
1825
1826        <para>
1827         For example, <literal>INTERVAL 'P1Y2M3DT4H5M6.7S'</> is now
1828         supported.
1829        </para>
1830       </listitem>
1831
1832       <listitem>
1833        <para>
1834         Add <varname>IntervalStyle</> parameter
1835         which controls how <type>interval</> values are output (Ron Mayer)
1836        </para>
1837
1838        <para>
1839         Valid values are:  <literal>postgres</>, <literal>postgres_verbose</>,
1840         <literal>sql_standard</>, <literal>iso_8601</>.  This setting also
1841         controls the handling of negative <type>interval</> input when only
1842         some fields have positive/negative designations.
1843        </para>
1844       </listitem>
1845
1846       <listitem>
1847        <para>
1848         Improve consistency of handling of fractional seconds in
1849         <type>timestamp</> and <type>interval</> output (Ron Mayer)
1850        </para>
1851       </listitem>
1852
1853      </itemizedlist>
1854
1855     </sect4>
1856
1857     <sect4>
1858      <title>Arrays</title>
1859      <itemizedlist>
1860
1861       <listitem>
1862        <para>
1863         Improve the handling of casts applied to <literal>ARRAY[]</>
1864         constructs, such as <literal>ARRAY[...]::integer[]</>
1865         (Brendan Jurd)
1866        </para>
1867
1868        <para>
1869         Formerly <productname>PostgreSQL</> attempted to determine a data type
1870         for the <literal>ARRAY[]</> construct without reference to the ensuing
1871         cast.  This could fail unnecessarily in many cases, in particular when
1872         the <literal>ARRAY[]</> construct was empty or contained only
1873         ambiguous entries such as <literal>NULL</>.  Now the cast is consulted
1874         to determine the type that the array elements must be.
1875        </para>
1876       </listitem>
1877
1878       <listitem>
1879        <para>
1880         Make <acronym>SQL</>-syntax <type>ARRAY</> dimensions optional
1881         to match the <acronym>SQL</> standard (Peter)
1882        </para>
1883       </listitem>
1884
1885       <listitem>
1886        <para>
1887         Add <function>array_ndims()</> to return the number
1888         of dimensions of an array (Robert Haas)
1889        </para>
1890       </listitem>
1891
1892       <listitem>
1893        <para>
1894         Add <function>array_length()</> to return the length
1895         of an array for a specified dimension (Jim Nasby, Robert
1896         Haas, Peter Eisentraut)
1897        </para>
1898       </listitem>
1899
1900       <listitem>
1901        <para>
1902         Add aggregate function <function>array_agg()</>, which
1903         returns all aggregated values as a single array (Robert Haas,
1904         Jeff Davis, Peter)
1905        </para>
1906       </listitem>
1907
1908       <listitem>
1909        <para>
1910         Add <function>unnest()</>, which converts an array to
1911         individual row values (Tom)
1912        </para>
1913
1914        <para>
1915         This is the opposite of <function>array_agg()</>.
1916        </para>
1917       </listitem>
1918
1919       <listitem>
1920        <para>
1921         Add <function>array_fill()</> to create arrays initialized with
1922         a value (Pavel Stehule)
1923        </para>
1924       </listitem>
1925
1926       <listitem>
1927        <para>
1928         Add <function>generate_subscripts()</> to simplify generating
1929         the range of an array's subscripts (Pavel Stehule)
1930        </para>
1931       </listitem>
1932
1933      </itemizedlist>
1934
1935     </sect4>
1936
1937     <sect4>
1938      <title>Wide-Value Storage (<acronym>TOAST</>)</title>
1939      <itemizedlist>
1940
1941       <listitem>
1942        <para>
1943         Consider <acronym>TOAST</> compression on values as short as
1944         32 bytes (previously 256 bytes) (Greg Stark)
1945        </para>
1946       </listitem>
1947
1948       <listitem>
1949        <para>
1950         Require 25% minimum space savings before using <acronym>TOAST</>
1951         compression (previously 20% for small values and any-savings-at-all
1952         for large values) (Greg)
1953        </para>
1954       </listitem>
1955
1956       <listitem>
1957        <para>
1958         Improve <acronym>TOAST</> heuristics for rows that have a mix of large
1959         and small toastable fields, so that we prefer to push large values out
1960         of line and don't compress small values unnecessarily (Greg, Tom)
1961        </para>
1962       </listitem>
1963
1964      </itemizedlist>
1965
1966     </sect4>
1967
1968    </sect3>
1969
1970    <sect3>
1971     <title>Functions</title>
1972     <itemizedlist>
1973
1974      <listitem>
1975       <para>
1976        Document that <function>setseed()</> allows values from
1977        <literal>-1</> to <literal>1</> (not just <literal>0</> to
1978        <literal>1</>), and enforce the valid range (Kris Jurka)
1979       </para>
1980      </listitem>
1981
1982      <listitem>
1983       <para>
1984        Add server-side function <function>lo_import(filename, oid)</>
1985        (Tatsuo)
1986       </para>
1987      </listitem>
1988
1989      <listitem>
1990       <para>
1991        Add <function>quote_nullable()</>, which behaves like
1992        <function>quote_literal()</> but returns the string <literal>NULL</> for
1993        a null argument (Brendan Jurd)
1994       </para>
1995      </listitem>
1996
1997      <listitem>
1998       <para>
1999        Improve full text search <function>headline()</> function to
2000        allow extracting several fragments of text (Sushant Sinha)
2001       </para>
2002      </listitem>
2003
2004      <listitem>
2005       <para>
2006        Add <function>suppress_redundant_updates_trigger()</> trigger
2007        function to avoid overhead for non-data-changing updates (Andrew)
2008       </para>
2009      </listitem>
2010
2011      <listitem>
2012       <para>
2013        Add <function>div(numeric, numeric)</> to perform <type>numeric</>
2014        division without rounding (Tom)
2015       </para>
2016      </listitem>
2017
2018      <listitem>
2019       <para>
2020        Add <type>timestamp</> and <type>timestamptz</> versions of
2021        <function>generate_series()</> (Hitoshi Harada)
2022       </para>
2023      </listitem>
2024
2025     </itemizedlist>
2026
2027     <sect4>
2028      <title>Object Information Functions</title>
2029      <itemizedlist>
2030
2031       <listitem>
2032        <para>
2033         Implement <function>current_query()</> for use by functions
2034         that need to know the currently running query (Tomas Doran)
2035        </para>
2036       </listitem>
2037
2038       <listitem>
2039        <para>
2040         Add <function>pg_get_keywords()</> to return a list of the
2041         parser keywords (Dave Page)
2042        </para>
2043       </listitem>
2044
2045       <listitem>
2046        <para>
2047         Add <function>pg_get_functiondef()</> to see a function's
2048         definition (Abhijit Menon-Sen)
2049        </para>
2050       </listitem>
2051
2052       <listitem>
2053        <para>
2054         Modify <function>pg_relation_size()</> to use <literal>regclass</>
2055         (Heikki)
2056        </para>
2057
2058        <para>
2059         <function>pg_relation_size(data_type_name)</> no longer works.
2060        </para>
2061       </listitem>
2062
2063       <listitem>
2064        <para>
2065         Add <literal>boot_val</> and <literal>reset_val</> columns to
2066         <literal>pg_settings</> output (Greg Smith)
2067        </para>
2068       </listitem>
2069
2070       <listitem>
2071        <para>
2072         Add source file name and line number columns to
2073         <literal>pg_settings</> output for variables set in a configuration
2074         file (Magnus, Alvaro)
2075        </para>
2076
2077        <para>
2078         For security reasons, these columns are only visible to superusers.
2079        </para>
2080       </listitem>
2081
2082       <listitem>
2083        <para>
2084         Add support for <varname>CURRENT_CATALOG</>,
2085         <varname>CURRENT_SCHEMA</>, <varname>SET CATALOG</>, <varname>SET
2086         SCHEMA</> (Peter)
2087        </para>
2088
2089        <para>
2090         These provide <acronym>SQL</>-standard syntax for existing features.
2091        </para>
2092       </listitem>
2093
2094       <listitem>
2095        <para>
2096         Add <function>pg_typeof()</> which returns the data type
2097         of any value (Brendan Jurd)
2098        </para>
2099       </listitem>
2100
2101       <listitem>
2102        <para>
2103         Make <function>version()</> return information about whether
2104         the server is a 32- or 64-bit binary (Bruce)
2105        </para>
2106       </listitem>
2107
2108       <listitem>
2109        <para>
2110         Fix the behavior of information schema columns
2111         <literal>is_insertable_into</> and <literal>is_updatable</> to
2112         be consistent (Peter)
2113        </para>
2114       </listitem>
2115
2116       <listitem>
2117        <para>
2118         Convert remaining builtin set-returning functions to use
2119         <literal>OUT</> parameters (Jaime Casanova)
2120        </para>
2121
2122        <para>
2123         This makes it possible to call these functions without specifying
2124         a column list:  <function>pg_show_all_settings()</>,
2125         <function>pg_lock_status()</>, <function>pg_prepared_xact()</>,
2126         <function>pg_prepared_statement()</>, <function>pg_cursor()</>
2127        </para>
2128       </listitem>
2129
2130       <listitem>
2131        <para>
2132         Make <function>pg_*_is_visible()</> and
2133         <function>has_*_privilege()</> functions return <literal>NULL</>
2134         for invalid OIDs, rather than reporting an error (Tom)
2135        </para>
2136       </listitem>
2137
2138       <listitem>
2139        <para>
2140         Extend <function>has_*_privilege()</> functions to allow inquiring
2141         about the OR of multiple privileges in one call (Stephen
2142         Frost, Tom)
2143        </para>
2144       </listitem>
2145
2146       <listitem>
2147        <para>
2148         Add <function>has_column_privilege()</> and
2149         <function>has_any_column_privilege()</> functions (Stephen
2150         Frost, Tom)
2151        </para>
2152       </listitem>
2153
2154      </itemizedlist>
2155
2156     </sect4>
2157
2158     <sect4>
2159      <title>Function Creation</title>
2160      <itemizedlist>
2161
2162       <listitem>
2163        <para>
2164         Support variadic functions (functions with a variable number
2165         of arguments) (Pavel Stehule)
2166        </para>
2167
2168        <para>
2169         Only trailing arguments can be optional, and they all must be
2170         of the same data type.
2171        </para>
2172       </listitem>
2173
2174       <listitem>
2175        <para>
2176         Support default values for function arguments (Pavel Stehule)
2177        </para>
2178       </listitem>
2179
2180       <listitem>
2181        <para>
2182         Add <command>CREATE FUNCTION ... RETURNS TABLE</> clause (Pavel
2183         Stehule)
2184        </para>
2185       </listitem>
2186
2187       <listitem>
2188        <para>
2189         Allow <acronym>SQL</>-language functions to return the output
2190         of an <command>INSERT</>/<command>UPDATE</>/<command>DELETE</>
2191         <literal>RETURNING</> clause (Tom)
2192        </para>
2193       </listitem>
2194
2195      </itemizedlist>
2196
2197     </sect4>
2198
2199     <sect4>
2200      <title>PL/PgSQL Server-Side Language</title>
2201      <itemizedlist>
2202
2203       <listitem>
2204        <para>
2205         Support <literal>EXECUTE USING</> for easier insertion of data
2206         values into a dynamic query string (Pavel Stehule)
2207        </para>
2208       </listitem>
2209
2210       <listitem>
2211        <para>
2212         Allow looping over the results of a cursor using a <literal>FOR</>
2213         loop (Pavel Stehule)
2214        </para>
2215       </listitem>
2216
2217       <listitem>
2218        <para>
2219         Support <literal>RETURN QUERY EXECUTE</> (Pavel
2220         Stehule)
2221        </para>
2222       </listitem>
2223
2224       <listitem>
2225        <para>
2226         Improve the <literal>RAISE</> command (Pavel Stehule)
2227
2228         <itemizedlist>
2229          <listitem>
2230           <para>
2231            Support <literal>DETAIL</> and <literal>HINT</> fields
2232           </para>
2233          </listitem>
2234          <listitem>
2235           <para>
2236            Support specification of the <literal>SQLSTATE</> error code
2237           </para>
2238          </listitem>
2239          <listitem>
2240           <para>
2241            Support an exception name parameter
2242           </para>
2243          </listitem>
2244          <listitem>
2245           <para>
2246            Allow <literal>RAISE</> without parameters in an exception
2247            block to re-throw the current error
2248           </para>
2249          </listitem>
2250         </itemizedlist>
2251        </para>
2252       </listitem>
2253
2254       <listitem>
2255        <para>
2256         Allow specification of <varname>SQLSTATE</> codes
2257         in <literal>EXCEPTION</> lists (Pavel Stehule)
2258        </para>
2259
2260        <para>
2261         This is useful for handling custom <varname>SQLSTATE</> codes.
2262        </para>
2263       </listitem>
2264
2265       <listitem>
2266        <para>
2267         Support the <literal>CASE</> statement (Pavel Stehule)
2268        </para>
2269       </listitem>
2270
2271       <listitem>
2272        <para>
2273         Make <command>RETURN QUERY</> set the special <literal>FOUND</> and
2274         <command>GET DIAGNOSTICS</> <literal>ROW_COUNT</> variables
2275         (Pavel Stehule)
2276        </para>
2277       </listitem>
2278
2279       <listitem>
2280        <para>
2281         Make <command>FETCH</> and <command>MOVE</> set the
2282         <command>GET DIAGNOSTICS</> <literal>ROW_COUNT</> variable
2283         (Andrew Gierth)
2284        </para>
2285       </listitem>
2286
2287       <listitem>
2288        <para>
2289         Make <command>EXIT</> without a label always exit the innermost
2290         loop (Tom)
2291        </para>
2292
2293        <para>
2294         Formerly, if there were a <literal>BEGIN</> block more closely nested
2295         than any loop, it would exit that block instead.  The new behavior
2296         matches Oracle(TM) and is also what was previously stated by our own
2297         documentation.
2298        </para>
2299       </listitem>
2300
2301       <listitem>
2302        <para>
2303         Make processing of string literals and nested block comments
2304         match the main SQL parser's processing (Tom)
2305        </para>
2306
2307        <para>
2308         In particular, the format string in <command>RAISE</> now works
2309         the same as any other string literal, including being subject
2310         to <varname>standard_conforming_strings</>.  This change also
2311         fixes other cases in which valid commands would fail when
2312         <varname>standard_conforming_strings</> is on.
2313        </para>
2314       </listitem>
2315
2316       <listitem>
2317        <para>
2318         Avoid memory leakage when the same function is called at varying
2319         exception-block nesting depths (Tom)
2320        </para>
2321       </listitem>
2322
2323      </itemizedlist>
2324
2325     </sect4>
2326
2327    </sect3>
2328
2329    <sect3>
2330     <title>Client Applications</title>
2331
2332     <itemizedlist>
2333
2334      <listitem>
2335       <para>
2336        Fix <literal>pg_ctl restart</> to preserve command-line arguments
2337        (Bruce)
2338       </para>
2339      </listitem>
2340
2341      <listitem>
2342       <para>
2343        Add <literal>-w</>/<literal>--no-password</> option that
2344        prevents password prompting in all utilities that have a
2345        <literal>-W</>/<literal>--password</> option (Peter)
2346       </para>
2347      </listitem>
2348
2349      <listitem>
2350       <para>
2351        Remove <option>-q</> (quiet) option of <application>createdb</>,
2352        <application>createuser</>, <application>dropdb</>,
2353        <application>dropuser</> (Peter)
2354       </para>
2355
2356       <para>
2357        These options have had no effect since <productname>PostgreSQL</>
2358        8.3.
2359       </para>
2360      </listitem>
2361
2362     </itemizedlist>
2363
2364     <sect4>
2365      <title><application>psql</></title>
2366      <itemizedlist>
2367
2368       <listitem>
2369        <para>
2370         Remove verbose startup banner; now just suggest <literal>help</>
2371         (Joshua Drake)
2372        </para>
2373       </listitem>
2374
2375       <listitem>
2376        <para>
2377         Make <literal>help</> show common backslash commands (Greg
2378         Sabino Mullane)
2379        </para>
2380       </listitem>
2381
2382       <listitem>
2383        <para>
2384         Add <literal>\pset format wrapped</> mode to wrap output to the
2385         screen width, or file/pipe output too if <literal>\pset columns</>
2386         is set (Bryce Nesbitt)
2387        </para>
2388       </listitem>
2389
2390       <listitem>
2391        <para>
2392         Allow all supported spellings of boolean values in <command>\pset</>,
2393         rather than just <literal>on</> and <literal>off</> (Bruce)
2394        </para>
2395
2396        <para>
2397         Formerly, any string other than <quote>off</> was silently taken
2398         to mean <literal>true</>.  <application>psql</> will now complain
2399         about unrecognized spellings (but still take them as <literal>true</>).
2400        </para>
2401       </listitem>
2402
2403       <listitem>
2404        <para>
2405         Use the pager for wide output (Bruce)
2406        </para>
2407       </listitem>
2408
2409       <listitem>
2410        <para>
2411         Require a space between a one-letter backslash command and its first
2412         argument (Bernd Helmle)
2413        </para>
2414
2415        <para>
2416         This removes a historical source of ambiguity.
2417        </para>
2418       </listitem>
2419
2420       <listitem>
2421        <para>
2422         Improve tab completion support for schema-qualified and
2423         quoted identifiers (Greg Sabino Mullane)
2424        </para>
2425       </listitem>
2426
2427       <listitem>
2428        <para>
2429         Add optional <literal>on</>/<literal>off</> argument for
2430         <command>\timing</> (David Fetter)
2431        </para>
2432       </listitem>
2433
2434       <listitem>
2435        <para>
2436         Display access control rights on multiple lines (Brendan
2437         Jurd, Andreas Scherbaum)
2438        </para>
2439       </listitem>
2440
2441       <listitem>
2442        <para>
2443         Make <command>\l</> show database access privileges (Andrew Gilligan)
2444        </para>
2445       </listitem>
2446
2447       <listitem>
2448        <para>
2449         Make <command>\l+</> show database sizes, if permissions
2450         allow (Andrew Gilligan)
2451        </para>
2452       </listitem>
2453
2454       <listitem>
2455        <para>
2456         Add the <command>\ef</> command to edit function definitions
2457         (Abhijit Menon-Sen)
2458        </para>
2459       </listitem>
2460
2461      </itemizedlist>
2462
2463     </sect4>
2464
2465     <sect4>
2466      <title><application>psql</> \d* commands</title>
2467
2468      <itemizedlist>
2469
2470       <listitem>
2471        <para>
2472         Make <command>\d*</> commands that do not have a pattern argument
2473         show system objects only if the <literal>S</> modifier is specified
2474         (Greg Sabino Mullane, Bruce)
2475        </para>
2476
2477        <para>
2478         The former behavior was inconsistent across different variants
2479         of <command>\d</>, and in most cases it provided no easy way to see
2480         just user objects.
2481        </para>
2482       </listitem>
2483
2484       <listitem>
2485        <para>
2486         Improve <command>\d*</> commands to work with older
2487         <productname>PostgreSQL</> server versions (back to 7.4),
2488         not only the current server version
2489         (Guillaume Lelarge)
2490        </para>
2491       </listitem>
2492
2493       <listitem>
2494        <para>
2495         Make <command>\d</> show foreign-key constraints that reference
2496         the selected table (Kenneth D'Souza)
2497        </para>
2498       </listitem>
2499
2500       <listitem>
2501        <para>
2502         Make <command>\d</> on a sequence show its column values
2503         (Euler Taveira de Oliveira)
2504        </para>
2505       </listitem>
2506
2507       <listitem>
2508        <para>
2509         Add column storage type and other relation options to the
2510         <command>\d+</> display (Gregory Stark, Euler Taveira de
2511         Oliveira)
2512        </para>
2513       </listitem>
2514
2515       <listitem>
2516        <para>
2517         Show relation size in <command>\dt+</> output (Dickson S.
2518         Guedes)
2519        </para>
2520       </listitem>
2521
2522       <listitem>
2523        <para>
2524         Show the possible values of <literal>enum</> types in <command>\dT+</>
2525         (David Fetter)
2526        </para>
2527       </listitem>
2528
2529       <listitem>
2530        <para>
2531         Allow <command>\dC</> to accept a wildcard pattern, which matches
2532         either datatype involved in the cast (Tom)
2533        </para>
2534       </listitem>
2535
2536       <listitem>
2537        <para>
2538         Add a function type column to <command>\df</>'s output, and add
2539         options to list only selected types of functions (David Fetter)
2540        </para>
2541       </listitem>
2542
2543       <listitem>
2544        <para>
2545         Make <command>\df</> not hide functions that take or return
2546         type <type>cstring</> (Tom)
2547        </para>
2548
2549        <para>
2550         Previously, such functions were hidden because most of them are
2551         datatype I/O functions, which were deemed uninteresting.  The new
2552         policy about hiding system functions by default makes this wart
2553         unnecessary.
2554        </para>
2555       </listitem>
2556
2557      </itemizedlist>
2558
2559     </sect4>
2560
2561     <sect4>
2562      <title><application>pg_dump</></title>
2563      <itemizedlist>
2564
2565       <listitem>
2566        <para>
2567         Add a <literal>--no-tablespaces</> option to
2568         <application>pg_dump</>/<application>pg_dumpall</>/<application>pg_restore</>
2569         so that dumps can be restored to clusters that have non-matching
2570         tablespace layouts (Gavin Roy)
2571        </para>
2572       </listitem>
2573
2574       <listitem>
2575        <para>
2576         Remove <option>-d</> and <option>-D</> options from
2577         <application>pg_dump</> and <application>pg_dumpall</> (Tom)
2578        </para>
2579
2580        <para>
2581         These options were too frequently confused with the option to
2582         select a database name in other <productname>PostgreSQL</>
2583         client applications.  The functionality is still available,
2584         but you must now spell out the long option name
2585         <option>--inserts</> or <option>--column-inserts</>.
2586        </para>
2587       </listitem>
2588
2589       <listitem>
2590        <para>
2591         Remove <option>-i</>/<option>--ignore-version</> option from
2592         <application>pg_dump</> and <application>pg_dumpall</> (Tom)
2593        </para>
2594
2595        <para>
2596         Use of this option does not throw an error, but it has no
2597         effect.  This option was removed because the version checks
2598         are necessary for safety.
2599        </para>
2600       </listitem>
2601
2602       <listitem>
2603        <para>
2604         Disable <varname>statement_timeout</> during dump and restore
2605         (Joshua Drake)
2606        </para>
2607       </listitem>
2608
2609       <listitem>
2610        <para>
2611         Add <application>pg_dump</>/<application>pg_dumpall</> option
2612         <option>--lock-wait-timeout</> (David Gould)
2613        </para>
2614
2615        <para>
2616         This allows dumps to fail if unable to acquire a shared lock
2617         within the specified amount of time.
2618        </para>
2619       </listitem>
2620
2621       <listitem>
2622        <para>
2623         Reorder <application>pg_dump</> <literal>--data-only</> output
2624         to dump tables referenced by foreign keys before
2625         the referencing tables (Tom)
2626        </para>
2627
2628        <para>
2629         This allows data loads when foreign keys are already present.
2630         If circular references make a safe ordering impossible, a
2631         <literal>NOTICE</> is issued.
2632        </para>
2633       </listitem>
2634
2635       <listitem>
2636        <para>
2637         Allow <application>pg_dump</>, <application>pg_dumpall</>, and
2638         <application>pg_restore</> to use a specified role (Benedek
2639         László)
2640        </para>
2641       </listitem>
2642
2643       <listitem>
2644        <para>
2645         Allow <application>pg_restore</> to use multiple concurrent
2646         connections to do the restore (Andrew)
2647        </para>
2648
2649        <para>
2650         The number of concurrent connections is controlled by the option
2651         <literal>--jobs</>.  This is supported only for custom-format archives.
2652        </para>
2653       </listitem>
2654
2655      </itemizedlist>
2656
2657     </sect4>
2658
2659    </sect3>
2660
2661    <sect3>
2662     <title>Programming Tools</title>
2663
2664     <sect4>
2665      <title><application>libpq</></title>
2666      <itemizedlist>
2667
2668       <listitem>
2669        <para>
2670         Allow the <type>OID</> to be specified when importing a large
2671         object, via new function <function>lo_import_with_oid()</> (Tatsuo)
2672        </para>
2673       </listitem>
2674
2675       <listitem>
2676        <para>
2677         Add <quote>events</> support (Andrew Chernow, Merlin Moncure)
2678        </para>
2679
2680        <para>
2681         This adds the ability to register callbacks to manage private
2682         data associated with <structname>PGconn</> and <structname>PGresult</>
2683         objects.
2684        </para>
2685       </listitem>
2686
2687       <listitem>
2688        <para>
2689         Improve error handling to allow the return of multiple
2690         error messages as multi-line error reports (Magnus)
2691        </para>
2692       </listitem>
2693
2694       <listitem>
2695        <para>
2696         Make <function>PQexecParams()</> and related functions return
2697         <varname>PGRES_EMPTY_QUERY</> for an empty query (Tom)
2698        </para>
2699
2700        <para>
2701         They previously returned <varname>PGRES_COMMAND_OK</>.
2702        </para>
2703       </listitem>
2704
2705       <listitem>
2706        <para>
2707         Document how to avoid the overhead of <function>WSACleanup()</>
2708         on Windows (Andrew Chernow)
2709        </para>
2710       </listitem>
2711
2712       <listitem>
2713        <para>
2714         Do not rely on Kerberos tickets to determine the default database
2715         username (Magnus)
2716        </para>
2717
2718        <para>
2719         Previously, a Kerberos-capable build of libpq would use the
2720         principal name from any available Kerberos ticket as default
2721         database username, even if the connection wasn't using Kerberos
2722         authentication.  This was deemed inconsistent and confusing.
2723         The default username is now determined the same way with or
2724         without Kerberos.  Note however that the database username must still
2725         match the ticket when Kerberos authentication is used.
2726        </para>
2727       </listitem>
2728      </itemizedlist>
2729
2730     </sect4>
2731
2732     <sect4>
2733      <title><application>libpq</> <acronym>SSL</> (Secure Sockets Layer)
2734       support</title>
2735      <itemizedlist>
2736
2737       <listitem>
2738        <para>
2739         Fix certificate validation for <acronym>SSL</> connections
2740         (Magnus)
2741        </para>
2742
2743        <para>
2744         <application>libpq</> now supports verifying both the certificate
2745         and the name of the server when making <acronym>SSL</>
2746         connections. If a root certificate is not available to use for
2747         verification, <acronym>SSL</> connections will fail. The
2748         <literal>sslmode</> parameter is used to enable certificate
2749         verification and set the level of checking.
2750         The default is still not to do any verification, allowing connections
2751         to SSL-enabled servers without requiring a root certificate on the
2752         client.
2753        </para>
2754       </listitem>
2755
2756       <listitem>
2757        <para>
2758         Support wildcard server certificates (Magnus)
2759        </para>
2760
2761        <para>
2762         If a certificate <acronym>CN</> starts with <literal>*</>, it will
2763         be treated as a wildcard when matching the hostname, allowing the
2764         use of the same certificate for multiple servers.
2765        </para>
2766       </listitem>
2767
2768       <listitem>
2769        <para>
2770         Allow the file locations for client certificates to be specified
2771         (Mark Woodward, Alvaro, Magnus)
2772        </para>
2773       </listitem>
2774
2775       <listitem>
2776        <para>
2777         Add a <function>PQinitOpenSSL</> function to allow greater control
2778         over OpenSSL/libcrypto initialization (Andrew Chernow)
2779        </para>
2780       </listitem>
2781
2782       <listitem>
2783        <para>
2784         Make <application>libpq</> unregister its <application>OpenSSL</>
2785         callbacks when no database connections remain open
2786         (Bruce, Magnus, Russell Smith)
2787        </para>
2788
2789        <para>
2790         This is required for applications that unload the libpq library,
2791         otherwise invalid <application>OpenSSL</> callbacks will remain.
2792        </para>
2793       </listitem>
2794
2795      </itemizedlist>
2796
2797     </sect4>
2798
2799     <sect4>
2800      <title><application>ecpg</></title>
2801      <itemizedlist>
2802
2803       <listitem>
2804        <para>
2805         Add localization support for messages (Euler Taveira de
2806         Oliveira)
2807        </para>
2808       </listitem>
2809
2810       <listitem>
2811        <para>
2812         ecpg parser is now automatically generated from the server
2813         parser (Michael)
2814        </para>
2815
2816        <para>
2817         Previously the ecpg parser was hand-maintained.
2818        </para>
2819       </listitem>
2820
2821      </itemizedlist>
2822
2823     </sect4>
2824
2825     <sect4>
2826      <title>Server Programming Interface (<acronym>SPI</>)</title>
2827      <itemizedlist>
2828
2829       <listitem>
2830        <para>
2831         Add support for single-use plans with out-of-line
2832         parameters (Tom)
2833        </para>
2834       </listitem>
2835
2836       <listitem>
2837        <para>
2838         Add new <varname>SPI_OK_REWRITTEN</> return code for
2839         <function>SPI_execute()</> (Heikki)
2840        </para>
2841
2842        <para>
2843         This is used when a command is rewritten to another type of
2844         command.
2845        </para>
2846       </listitem>
2847
2848       <listitem>
2849        <para>
2850         Remove unnecessary inclusions from <filename>executor/spi.h</> (Tom)
2851        </para>
2852
2853        <para>
2854         SPI-using modules might need to add some <literal>#include</>
2855         lines if they were depending on <filename>spi.h</> to include
2856         things for them.
2857        </para>
2858       </listitem>
2859
2860      </itemizedlist>
2861
2862     </sect4>
2863
2864    </sect3>
2865
2866    <sect3>
2867     <title>Build Options</title>
2868     <itemizedlist>
2869
2870      <listitem>
2871       <para>
2872        Update build system to use <productname>Autoconf</> 2.61 (Peter)
2873       </para>
2874      </listitem>
2875
2876      <listitem>
2877       <para>
2878        Require <productname>GNU bison</> for source code builds (Peter)
2879       </para>
2880
2881       <para>
2882        This has effectively been required for several years, but now there
2883        is no infrastructure claiming to support other parser tools.
2884       </para>
2885      </listitem>
2886
2887      <listitem>
2888       <para>
2889        Add <application>pg_config</> <literal>--htmldir</> option
2890        (Peter)
2891       </para>
2892      </listitem>
2893
2894      <listitem>
2895       <para>
2896        Pass <type>float4</> by value inside the server (Zoltan
2897        Boszormenyi)
2898       </para>
2899
2900       <para>
2901        Add <application>configure</> option
2902        <literal>--disable-float4-byval</> to use the old behavior.
2903        External C functions that use old-style (version 0) call convention
2904        and pass or return <type>float4</> values will be broken by this
2905        change, so you may need the <application>configure</> option if you
2906        have such functions and don't want to update them.
2907       </para>
2908      </listitem>
2909
2910      <listitem>
2911       <para>
2912        Pass <type>float8</>, <type>int8</>, and related datatypes
2913        by value inside the server on 64-bit platforms (Zoltan Boszormenyi)
2914       </para>
2915
2916       <para>
2917        Add <application>configure</> option
2918        <literal>--disable-float8-byval</> to use the old behavior.
2919        As above, this change might break old-style external C functions.
2920       </para>
2921      </listitem>
2922
2923      <listitem>
2924       <para>
2925        Add configure options <literal>--with-segsize</>,
2926        <literal>--with-blocksize</>, <literal>--with-wal-blocksize</>,
2927        <literal>--with-wal-segsize</> (Zdenek Kotala, Tom)
2928       </para>
2929
2930       <para>
2931        This simplifies build-time control over several constants that
2932        previously could only be changed by editing
2933        <filename>pg_config_manual.h</>.
2934       </para>
2935      </listitem>
2936
2937      <listitem>
2938       <para>
2939        Allow threaded builds on <productname>Solaris</> 2.5 (Bruce)
2940       </para>
2941      </listitem>
2942
2943      <listitem>
2944       <para>
2945        Use the system's <function>getopt_long()</> on <productname>Solaris</>
2946        (Zdenek Kotala, Tom)
2947       </para>
2948
2949       <para>
2950        This makes option processing more consistent with what Solaris users
2951        expect.
2952       </para>
2953      </listitem>
2954
2955      <listitem>
2956       <para>
2957        Add support for the <productname>Sun Studio</> compiler on
2958        <productname>Linux</> (Julius Stroffek)
2959       </para>
2960      </listitem>
2961
2962      <listitem>
2963       <para>
2964        Append the major version number to the backend <application>gettext</>
2965        domain, and the <literal>soname</> major version number to
2966        libraries' <application>gettext</> domain (Peter)
2967       </para>
2968
2969       <para>
2970        This simplifies parallel installations of multiple versions.
2971       </para>
2972      </listitem>
2973
2974      <listitem>
2975       <para>
2976        Add support for code coverage testing with <application>gcov</>
2977        (Michelle Caisse)
2978       </para>
2979      </listitem>
2980
2981      <listitem>
2982       <para>
2983        Allow out-of-tree builds on <productname>Mingw</> and
2984        <productname>Cygwin</> (Richard Evans)
2985       </para>
2986      </listitem>
2987
2988      <listitem>
2989       <para>
2990        Fix the use of <productname>Mingw</> as a cross-compiling source
2991        platform (Peter)
2992       </para>
2993      </listitem>
2994
2995     </itemizedlist>
2996
2997    </sect3>
2998
2999    <sect3>
3000     <title>Source Code</title>
3001     <itemizedlist>
3002
3003      <listitem>
3004       <para>
3005        Support 64-bit time zone data files (Heikki)
3006       </para>
3007
3008       <para>
3009        This adds support for daylight saving time (<acronym>DST</>)
3010        calculations beyond the year 2038.
3011       </para>
3012      </listitem>
3013
3014      <listitem>
3015       <para>
3016        Deprecate use of platform's <type>time_t</> data type (Tom)
3017       </para>
3018
3019       <para>
3020        Some platforms have migrated to 64-bit <type>time_t</>, some have
3021        not, and Windows can't make up its mind what it's doing.  Define
3022        <type>pg_time_t</> to have the same meaning as <type>time_t</>,
3023        but always be 64 bits (unless the platform has no 64-bit integer type),
3024        and use that type in all module APIs and on-disk data formats.
3025       </para>
3026      </listitem>
3027
3028      <listitem>
3029       <para>
3030        Fix bug in handling of the time zone database when cross-compiling
3031        (Richard Evans)
3032       </para>
3033      </listitem>
3034
3035      <listitem>
3036       <para>
3037        Link backend object files in one step, rather than in stages
3038        (Peter)
3039       </para>
3040      </listitem>
3041
3042      <listitem>
3043       <para>
3044        Improve <application>gettext</> support to allow better translation
3045        of plurals (Peter)
3046       </para>
3047      </listitem>
3048
3049      <listitem>
3050       <para>
3051        Add message translation support to the PL languages (Alvaro, Peter)
3052       </para>
3053      </listitem>
3054
3055      <listitem>
3056       <para>
3057        Add more <application>DTrace</> probes (Robert Lor)
3058       </para>
3059      </listitem>
3060
3061      <listitem>
3062       <para>
3063        Enable <application>DTrace</> support on <application>Mac OS X
3064        Leopard</> and other non-Solaris platforms (Robert Lor)
3065       </para>
3066      </listitem>
3067
3068      <listitem>
3069       <para>
3070        Simplify and standardize conversions between C strings and
3071        <type>text</> datums, by providing common functions for the purpose
3072        (Brendan Jurd, Tom)
3073       </para>
3074      </listitem>
3075
3076      <listitem>
3077       <para>
3078        Clean up the <filename>include/catalog/</> header files so that
3079        frontend programs can include them without including
3080        <filename>postgres.h</>
3081        (Zdenek Kotala)
3082       </para>
3083      </listitem>
3084
3085      <listitem>
3086       <para>
3087        Make <type>name</> char-aligned, and suppress zero-padding of
3088        <type>name</> entries in indexes (Tom)
3089       </para>
3090      </listitem>
3091
3092      <listitem>
3093       <para>
3094        Recover better if dynamically-loaded code executes <function>exit()</>
3095        (Tom)
3096       </para>
3097      </listitem>
3098
3099      <listitem>
3100       <para>
3101        Add a hook to let plug-ins monitor the executor (Itagaki
3102        Takahiro)
3103       </para>
3104      </listitem>
3105
3106      <listitem>
3107       <para>
3108        Add a hook to allow the planner's statistics lookup behavior to
3109        be overridden (Simon Riggs)
3110       </para>
3111      </listitem>
3112
3113      <listitem>
3114       <para>
3115        Add <function>shmem_startup_hook()</> for custom shared memory
3116        requirements (Tom)
3117       </para>
3118      </listitem>
3119
3120      <listitem>
3121       <para>
3122        Replace the index access method <function>amgetmulti</> entry point
3123        with <function>amgetbitmap</>, and extend the API for
3124        <function>amgettuple</> to support run-time determination of
3125        operator lossiness (Heikki, Tom, Teodor)
3126       </para>
3127
3128       <para>
3129        The API for GIN and GiST opclass <function>consistent</> functions
3130        has been extended as well.
3131       </para>
3132      </listitem>
3133
3134      <listitem>
3135       <para>
3136        Add support for partial-match searches in <acronym>GIN</> indexes
3137        (Teodor Sigaev, Oleg Bartunov)
3138       </para>
3139      </listitem>
3140
3141      <listitem>
3142       <para>
3143        Replace <structname>pg_class</> column <structfield>reltriggers</>
3144        with boolean <structfield>relhastriggers</> (Simon)
3145       </para>
3146
3147       <para>
3148        Also remove unused <structname>pg_class</> columns
3149        <structfield>relukeys</>, <structfield>relfkeys</>, and
3150        <structfield>relrefs</>.
3151       </para>
3152      </listitem>
3153
3154      <listitem>
3155       <para>
3156        Add a <structfield>relistemp</> column to <structname>pg_class</>
3157        to ease identification of temporary tables (Tom)
3158       </para>
3159      </listitem>
3160
3161      <listitem>
3162       <para>
3163        Move platform <acronym>FAQ</>s into the main documentation
3164        (Peter)
3165       </para>
3166      </listitem>
3167
3168      <listitem>
3169       <para>
3170        Prevent parser input files from being built with any conflicts
3171        (Peter)
3172       </para>
3173      </listitem>
3174
3175      <listitem>
3176       <para>
3177        Add support for the <literal>KOI8U</> (Ukrainian) encoding
3178        (Peter)
3179       </para>
3180      </listitem>
3181
3182      <listitem>
3183       <para>
3184        Add Japanese message translations (Japan PostgreSQL Users Group)
3185       </para>
3186
3187       <para>
3188        This used to be maintained as a separate project.
3189       </para>
3190      </listitem>
3191
3192      <listitem>
3193       <para>
3194        Fix problem when setting <varname>LC_MESSAGES</> on
3195        <application>MSVC</>-built systems (Hiroshi Inoue, Hiroshi
3196        Saito, Magnus)
3197       </para>
3198      </listitem>
3199
3200     </itemizedlist>
3201
3202    </sect3>
3203
3204    <sect3>
3205     <title>Contrib</title>
3206
3207     <itemizedlist>
3208
3209      <listitem>
3210       <para>
3211        Add <filename>contrib/auto_explain</> to automatically run
3212        <command>EXPLAIN</> on queries exceeding a specified duration
3213        (Itagaki Takahiro, Tom)
3214       </para>
3215      </listitem>
3216
3217      <listitem>
3218       <para>
3219        Add <filename>contrib/btree_gin</> to allow GIN indexes to
3220        handle more datatypes (Oleg, Teodor)
3221       </para>
3222      </listitem>
3223
3224      <listitem>
3225       <para>
3226        Add <filename>contrib/citext</> to provide a case-insensitive,
3227        multibyte-aware text data type (David Wheeler)
3228       </para>
3229      </listitem>
3230
3231      <listitem>
3232       <para>
3233        Add <filename>contrib/pg_stat_statements</> for server-wide
3234        tracking of statement execution statistics (Itagaki Takahiro)
3235       </para>
3236      </listitem>
3237
3238      <listitem>
3239       <para>
3240        Add duration and query mode options to <filename>contrib/pgbench</>
3241        (Itagaki Takahiro)
3242       </para>
3243      </listitem>
3244
3245      <listitem>
3246       <para>
3247        Make <filename>contrib/pgbench</> use table names
3248        <structname>pgbench_accounts</>, <structname>pgbench_branches</>,
3249        <structname>pgbench_history</>, and <structname>pgbench_tellers</>,
3250        rather than just <structname>accounts</>, <structname>branches</>,
3251        <structname>history</>, and <structname>tellers</> (Tom)
3252       </para>
3253
3254       <para>
3255        This is to reduce the risk of accidentally destroying real data
3256        by running <application>pgbench</>.
3257       </para>
3258      </listitem>
3259
3260      <listitem>
3261       <para>
3262        Fix <filename>contrib/pgstattuple</> to handle tables and
3263        indexes with over 2 billion pages (Tatsuhito Kasahara)
3264       </para>
3265      </listitem>
3266
3267      <listitem>
3268       <para>
3269        In <filename>contrib/fuzzystrmatch</>, add a version of the
3270        Levenshtein string-distance function that allows the user to
3271        specify the costs of insertion, deletion, and substitution
3272        (Volkan Yazici)
3273       </para>
3274      </listitem>
3275
3276      <listitem>
3277       <para>
3278        Make <filename>contrib/ltree</> support multibyte encodings
3279        (laser)
3280       </para>
3281      </listitem>
3282
3283      <listitem>
3284       <para>
3285        Improve <filename>contrib/dblink</>'s reporting of errors from
3286        the remote server (Joe Conway)
3287       </para>
3288      </listitem>
3289
3290      <listitem>
3291       <para>
3292        Make sure <filename>contrib/dblink</> uses a password supplied
3293        by the user, and not accidentally taken from the server's
3294        <filename>.pgpass</> file (Joe Conway)
3295       </para>
3296
3297       <para>
3298        This is a minor security enhancement.
3299       </para>
3300      </listitem>
3301
3302      <listitem>
3303       <para>
3304        Add <function>fsm_page_contents()</>
3305        to <filename>contrib/pageinspect</> (Heikki)
3306       </para>
3307      </listitem>
3308
3309      <listitem>
3310       <para>
3311        Modify <function>get_raw_page()</> to support free space map
3312        (<filename>*_fsm</>) files.  Also update
3313        <filename>contrib/pg_freespacemap</>.
3314       </para>
3315      </listitem>
3316
3317      <listitem>
3318       <para>
3319        Add support for multibyte encodings to <filename>contrib/pg_trgm</>
3320        (Teodor)
3321       </para>
3322      </listitem>
3323
3324      <listitem>
3325       <para>
3326        Rewrite <filename>contrib/intagg</> to use new
3327        functions <function>array_agg()</> and <function>unnest()</>
3328        (Tom)
3329       </para>
3330      </listitem>
3331
3332      <listitem>
3333       <para>
3334        Make <filename>contrib/pg_standby</> recover all available WAL before
3335        failover (Fujii Masao, Simon, Heikki)
3336       </para>
3337
3338       <para>
3339        To make this work safely, you now need to set the new
3340        <literal>recovery_end_command</> option in <filename>recovery.conf</>
3341        to clean up the trigger file after failover. <application>pg_standby</>
3342        will no longer remove the trigger file itself.
3343       </para>
3344      </listitem>
3345
3346     </itemizedlist>
3347
3348    </sect3>
3349   </sect2>
3350  </sect1>