]> granicus.if.org Git - postgresql/blob - doc/src/sgml/release-8.2.sgml
Trim trailing whitespace
[postgresql] / doc / src / sgml / release-8.2.sgml
1 <!-- doc/src/sgml/release-8.2.sgml -->
2 <!-- See header comment in release.sgml about typical markup -->
3
4  <sect1 id="release-8-2-23">
5   <title>Release 8.2.23</title>
6
7   <formalpara>
8   <title>Release date:</title>
9   <para>2011-12-05</para>
10   </formalpara>
11
12   <para>
13    This release contains a variety of fixes from 8.2.22.
14    For information about new features in the 8.2 major release, see
15    <xref linkend="release-8-2">.
16   </para>
17
18   <para>
19    This is expected to be the last <productname>PostgreSQL</> release
20    in the 8.2.X series.  Users are encouraged to update to a newer
21    release branch soon.
22   </para>
23
24   <sect2>
25    <title>Migration to Version 8.2.23</title>
26
27    <para>
28     A dump/restore is not required for those running 8.2.X.
29    </para>
30
31    <para>
32     However, a longstanding error was discovered in the definition of the
33     <literal>information_schema.referential_constraints</> view.  If you
34     rely on correct results from that view, you should replace its
35     definition as explained in the first changelog item below.
36    </para>
37
38    <para>
39     Also, if you are upgrading from a version earlier than 8.2.14,
40     see <xref linkend="release-8-2-14">.
41    </para>
42
43   </sect2>
44
45   <sect2>
46    <title>Changes</title>
47
48    <itemizedlist>
49
50     <listitem>
51      <para>
52       Fix bugs in <literal>information_schema.referential_constraints</> view
53       (Tom Lane)
54      </para>
55
56      <para>
57       This view was being insufficiently careful about matching the
58       foreign-key constraint to the depended-on primary or unique key
59       constraint.  That could result in failure to show a foreign key
60       constraint at all, or showing it multiple times, or claiming that it
61       depends on a different constraint than the one it really does.
62      </para>
63
64      <para>
65       Since the view definition is installed by <application>initdb</>,
66       merely upgrading will not fix the problem.  If you need to fix this
67       in an existing installation, you can (as a superuser) drop the
68       <literal>information_schema</> schema then re-create it by sourcing
69       <filename><replaceable>SHAREDIR</>/information_schema.sql</filename>.
70       (Run <literal>pg_config --sharedir</> if you're uncertain where
71       <replaceable>SHAREDIR</> is.)  This must be repeated in each database
72       to be fixed.
73      </para>
74     </listitem>
75
76     <listitem>
77      <para>
78       Fix TOAST-related data corruption during <literal>CREATE TABLE dest AS
79       SELECT * FROM src</> or <literal>INSERT INTO dest SELECT * FROM src</>
80       (Tom Lane)
81      </para>
82
83      <para>
84       If a table has been modified by <command>ALTER TABLE ADD COLUMN</>,
85       attempts to copy its data verbatim to another table could produce
86       corrupt results in certain corner cases.
87       The problem can only manifest in this precise form in 8.4 and later,
88       but we patched earlier versions as well in case there are other code
89       paths that could trigger the same bug.
90      </para>
91     </listitem>
92
93     <listitem>
94      <para>
95       Fix race condition during toast table access from stale syscache entries
96       (Tom Lane)
97      </para>
98
99      <para>
100       The typical symptom was transient errors like <quote>missing chunk
101       number 0 for toast value NNNNN in pg_toast_2619</>, where the cited
102       toast table would always belong to a system catalog.
103      </para>
104     </listitem>
105
106     <listitem>
107      <para>
108       Improve locale support in <type>money</> type's input and output
109       (Tom Lane)
110      </para>
111
112      <para>
113       Aside from not supporting all standard
114       <link linkend="guc-lc-monetary"><varname>lc_monetary</></link>
115       formatting options, the input and output functions were inconsistent,
116       meaning there were locales in which dumped <type>money</> values could
117       not be re-read.
118      </para>
119     </listitem>
120
121     <listitem>
122      <para>
123       Don't let <link
124       linkend="guc-transform-null-equals"><varname>transform_null_equals</></link>
125       affect <literal>CASE foo WHEN NULL ...</> constructs
126       (Heikki Linnakangas)
127      </para>
128
129      <para>
130       <varname>transform_null_equals</> is only supposed to affect
131       <literal>foo = NULL</> expressions written directly by the user, not
132       equality checks generated internally by this form of <literal>CASE</>.
133      </para>
134     </listitem>
135
136     <listitem>
137      <para>
138       Change foreign-key trigger creation order to better support
139       self-referential foreign keys (Tom Lane)
140      </para>
141
142      <para>
143       For a cascading foreign key that references its own table, a row update
144       will fire both the <literal>ON UPDATE</> trigger and the
145       <literal>CHECK</> trigger as one event.  The <literal>ON UPDATE</>
146       trigger must execute first, else the <literal>CHECK</> will check a
147       non-final state of the row and possibly throw an inappropriate error.
148       However, the firing order of these triggers is determined by their
149       names, which generally sort in creation order since the triggers have
150       auto-generated names following the convention
151       <quote>RI_ConstraintTrigger_NNNN</>.  A proper fix would require
152       modifying that convention, which we will do in 9.2, but it seems risky
153       to change it in existing releases.  So this patch just changes the
154       creation order of the triggers.  Users encountering this type of error
155       should drop and re-create the foreign key constraint to get its
156       triggers into the right order.
157      </para>
158     </listitem>
159
160     <listitem>
161      <para>
162       Preserve blank lines within commands in <application>psql</>'s command
163       history (Robert Haas)
164      </para>
165
166      <para>
167       The former behavior could cause problems if an empty line was removed
168       from within a string literal, for example.
169      </para>
170     </listitem>
171
172     <listitem>
173      <para>
174       Use the preferred version of <application>xsubpp</> to build PL/Perl,
175       not necessarily the operating system's main copy
176       (David Wheeler and Alex Hunsaker)
177      </para>
178     </listitem>
179
180     <listitem>
181      <para>
182       Honor query cancel interrupts promptly in <function>pgstatindex()</>
183       (Robert Haas)
184      </para>
185     </listitem>
186
187     <listitem>
188      <para>
189       Ensure VPATH builds properly install all server header files
190       (Peter Eisentraut)
191      </para>
192     </listitem>
193
194     <listitem>
195      <para>
196       Shorten file names reported in verbose error messages (Peter Eisentraut)
197      </para>
198
199      <para>
200       Regular builds have always reported just the name of the C file
201       containing the error message call, but VPATH builds formerly
202       reported an absolute path name.
203      </para>
204     </listitem>
205
206     <listitem>
207      <para>
208       Fix interpretation of Windows timezone names for Central America
209       (Tom Lane)
210      </para>
211
212      <para>
213       Map <quote>Central America Standard Time</> to <literal>CST6</>, not
214       <literal>CST6CDT</>, because DST is generally not observed anywhere in
215       Central America.
216      </para>
217     </listitem>
218
219     <listitem>
220      <para>
221       Update time zone data files to <application>tzdata</> release 2011n
222       for DST law changes in Brazil, Cuba, Fiji, Palestine, Russia, and Samoa;
223       also historical corrections for Alaska and British East Africa.
224      </para>
225     </listitem>
226
227    </itemizedlist>
228
229   </sect2>
230  </sect1>
231
232  <sect1 id="release-8-2-22">
233   <title>Release 8.2.22</title>
234
235   <formalpara>
236   <title>Release date:</title>
237   <para>2011-09-26</para>
238   </formalpara>
239
240   <para>
241    This release contains a variety of fixes from 8.2.21.
242    For information about new features in the 8.2 major release, see
243    <xref linkend="release-8-2">.
244   </para>
245
246   <para>
247    The <productname>PostgreSQL</> community will stop releasing updates
248    for the 8.2.X release series in December 2011.
249    Users are encouraged to update to a newer release branch soon.
250   </para>
251
252   <sect2>
253    <title>Migration to Version 8.2.22</title>
254
255    <para>
256     A dump/restore is not required for those running 8.2.X.
257     However, if you are upgrading from a version earlier than 8.2.14,
258     see <xref linkend="release-8-2-14">.
259    </para>
260
261   </sect2>
262
263   <sect2>
264    <title>Changes</title>
265
266    <itemizedlist>
267
268     <listitem>
269      <para>
270       Fix multiple bugs in GiST index page split processing (Heikki
271       Linnakangas)
272      </para>
273
274      <para>
275       The probability of occurrence was low, but these could lead to index
276       corruption.
277      </para>
278     </listitem>
279
280     <listitem>
281      <para>
282       Avoid possibly accessing off the end of memory in <command>ANALYZE</>
283       (Noah Misch)
284      </para>
285
286      <para>
287       This fixes a very-low-probability server crash scenario.
288      </para>
289     </listitem>
290
291     <listitem>
292      <para>
293       Fix race condition in relcache init file invalidation (Tom Lane)
294      </para>
295
296      <para>
297       There was a window wherein a new backend process could read a stale init
298       file but miss the inval messages that would tell it the data is stale.
299       The result would be bizarre failures in catalog accesses, typically
300       <quote>could not read block 0 in file ...</> later during startup.
301      </para>
302     </listitem>
303
304     <listitem>
305      <para>
306       Fix memory leak at end of a GiST index scan (Tom Lane)
307      </para>
308
309      <para>
310       Commands that perform many separate GiST index scans, such as
311       verification of a new GiST-based exclusion constraint on a table
312       already containing many rows, could transiently require large amounts of
313       memory due to this leak.
314      </para>
315     </listitem>
316
317     <listitem>
318      <para>
319       Fix performance problem when constructing a large, lossy bitmap
320       (Tom Lane)
321      </para>
322     </listitem>
323
324     <listitem>
325      <para>
326       Fix array- and path-creating functions to ensure padding bytes are
327       zeroes (Tom Lane)
328      </para>
329
330      <para>
331       This avoids some situations where the planner will think that
332       semantically-equal constants are not equal, resulting in poor
333       optimization.
334      </para>
335     </listitem>
336
337     <listitem>
338      <para>
339       Work around gcc 4.6.0 bug that breaks WAL replay (Tom Lane)
340      </para>
341
342      <para>
343       This could lead to loss of committed transactions after a server crash.
344      </para>
345     </listitem>
346
347     <listitem>
348      <para>
349       Fix dump bug for <literal>VALUES</> in a view (Tom Lane)
350      </para>
351     </listitem>
352
353     <listitem>
354      <para>
355       Disallow <literal>SELECT FOR UPDATE/SHARE</> on sequences (Tom Lane)
356      </para>
357
358      <para>
359       This operation doesn't work as expected and can lead to failures.
360      </para>
361     </listitem>
362
363     <listitem>
364      <para>
365       Defend against integer overflow when computing size of a hash table (Tom
366       Lane)
367      </para>
368     </listitem>
369
370     <listitem>
371      <para>
372       Fix portability bugs in use of credentials control messages for
373       <quote>peer</> authentication (Tom Lane)
374      </para>
375     </listitem>
376
377     <listitem>
378      <para>
379       Fix typo in <function>pg_srand48</> seed initialization (Andres Freund)
380      </para>
381
382      <para>
383       This led to failure to use all bits of the provided seed.  This function
384       is not used on most platforms (only those without <function>srandom</>),
385       and the potential security exposure from a less-random-than-expected
386       seed seems minimal in any case.
387      </para>
388     </listitem>
389
390     <listitem>
391      <para>
392       Avoid integer overflow when the sum of <literal>LIMIT</> and
393       <literal>OFFSET</> values exceeds 2^63 (Heikki Linnakangas)
394      </para>
395     </listitem>
396
397     <listitem>
398      <para>
399       Add overflow checks to <type>int4</> and <type>int8</> versions of
400       <function>generate_series()</> (Robert Haas)
401      </para>
402     </listitem>
403
404     <listitem>
405      <para>
406       Fix trailing-zero removal in <function>to_char()</> (Marti Raudsepp)
407      </para>
408
409      <para>
410       In a format with <literal>FM</> and no digit positions
411       after the decimal point, zeroes to the left of the decimal point could
412       be removed incorrectly.
413      </para>
414     </listitem>
415
416     <listitem>
417      <para>
418       Fix <function>pg_size_pretty()</> to avoid overflow for inputs close to
419       2^63 (Tom Lane)
420      </para>
421     </listitem>
422
423     <listitem>
424      <para>
425       Fix <application>psql</>'s counting of script file line numbers during
426       <literal>COPY</> from a different file (Tom Lane)
427      </para>
428     </listitem>
429
430     <listitem>
431      <para>
432       Fix <application>pg_restore</>'s direct-to-database mode for
433       <varname>standard_conforming_strings</> (Tom Lane)
434      </para>
435
436      <para>
437       <application>pg_restore</> could emit incorrect commands when restoring
438       directly to a database server from an archive file that had been made
439       with <varname>standard_conforming_strings</> set to <literal>on</>.
440      </para>
441     </listitem>
442
443     <listitem>
444      <para>
445       Fix write-past-buffer-end and memory leak in <application>libpq</>'s
446       LDAP service lookup code (Albe Laurenz)
447      </para>
448     </listitem>
449
450     <listitem>
451      <para>
452       In <application>libpq</>, avoid failures when using nonblocking I/O
453       and an SSL connection (Martin Pihlak, Tom Lane)
454      </para>
455     </listitem>
456
457     <listitem>
458      <para>
459       Improve libpq's handling of failures during connection startup
460       (Tom Lane)
461      </para>
462
463      <para>
464       In particular, the response to a server report of <function>fork()</>
465       failure during SSL connection startup is now saner.
466      </para>
467     </listitem>
468
469     <listitem>
470      <para>
471       Make <application>ecpglib</> write <type>double</> values with 15 digits
472       precision (Akira Kurosawa)
473      </para>
474     </listitem>
475
476     <listitem>
477      <para>
478       Apply upstream fix for blowfish signed-character bug (CVE-2011-2483)
479       (Tom Lane)
480      </para>
481
482      <para>
483       <filename>contrib/pg_crypto</>'s blowfish encryption code could give
484       wrong results on platforms where char is signed (which is most),
485       leading to encrypted passwords being weaker than they should be.
486      </para>
487     </listitem>
488
489     <listitem>
490      <para>
491       Fix memory leak in <filename>contrib/seg</> (Heikki Linnakangas)
492      </para>
493     </listitem>
494
495     <listitem>
496      <para>
497       Fix <function>pgstatindex()</> to give consistent results for empty
498       indexes (Tom Lane)
499      </para>
500     </listitem>
501
502     <listitem>
503      <para>
504       Allow building with perl 5.14 (Alex Hunsaker)
505      </para>
506     </listitem>
507
508     <listitem>
509      <para>
510       Update configure script's method for probing existence of system
511       functions (Tom Lane)
512      </para>
513
514      <para>
515       The version of autoconf we used in 8.3 and 8.2 could be fooled by
516       compilers that perform link-time optimization.
517      </para>
518     </listitem>
519
520     <listitem>
521      <para>
522       Fix assorted issues with build and install file paths containing spaces
523       (Tom Lane)
524      </para>
525     </listitem>
526
527     <listitem>
528      <para>
529       Update time zone data files to <application>tzdata</> release 2011i
530       for DST law changes in Canada, Egypt, Russia, Samoa, and South Sudan.
531      </para>
532     </listitem>
533
534    </itemizedlist>
535
536   </sect2>
537  </sect1>
538
539  <sect1 id="release-8-2-21">
540   <title>Release 8.2.21</title>
541
542   <formalpara>
543   <title>Release date:</title>
544   <para>2011-04-18</para>
545   </formalpara>
546
547   <para>
548    This release contains a variety of fixes from 8.2.20.
549    For information about new features in the 8.2 major release, see
550    <xref linkend="release-8-2">.
551   </para>
552
553   <sect2>
554    <title>Migration to Version 8.2.21</title>
555
556    <para>
557     A dump/restore is not required for those running 8.2.X.
558     However, if you are upgrading from a version earlier than 8.2.14,
559     see <xref linkend="release-8-2-14">.
560    </para>
561
562   </sect2>
563
564   <sect2>
565    <title>Changes</title>
566
567    <itemizedlist>
568
569     <listitem>
570      <para>
571       Avoid potential deadlock during catalog cache initialization
572       (Nikhil Sontakke)
573      </para>
574
575      <para>
576       In some cases the cache loading code would acquire share lock on a
577       system index before locking the index's catalog.  This could deadlock
578       against processes trying to acquire exclusive locks in the other,
579       more standard order.
580      </para>
581     </listitem>
582
583     <listitem>
584      <para>
585       Fix dangling-pointer problem in <literal>BEFORE ROW UPDATE</> trigger
586       handling when there was a concurrent update to the target tuple
587       (Tom Lane)
588      </para>
589
590      <para>
591       This bug has been observed to result in intermittent <quote>cannot
592       extract system attribute from virtual tuple</> failures while trying to
593       do <literal>UPDATE RETURNING ctid</>.  There is a very small probability
594       of more serious errors, such as generating incorrect index entries for
595       the updated tuple.
596      </para>
597     </listitem>
598
599     <listitem>
600      <para>
601       Disallow <command>DROP TABLE</> when there are pending deferred trigger
602       events for the table (Tom Lane)
603      </para>
604
605      <para>
606       Formerly the <command>DROP</> would go through, leading to
607       <quote>could not open relation with OID nnn</> errors when the
608       triggers were eventually fired.
609      </para>
610     </listitem>
611
612     <listitem>
613      <para>
614       Fix PL/Python memory leak involving array slices (Daniel Popowich)
615      </para>
616     </listitem>
617
618     <listitem>
619      <para>
620       Fix <application>pg_restore</> to cope with long lines (over 1KB) in
621       TOC files (Tom Lane)
622      </para>
623     </listitem>
624
625     <listitem>
626      <para>
627       Put in more safeguards against crashing due to division-by-zero
628       with overly enthusiastic compiler optimization (Aurelien Jarno)
629      </para>
630     </listitem>
631
632     <listitem>
633      <para>
634       Support use of dlopen() in FreeBSD and OpenBSD on MIPS (Tom Lane)
635      </para>
636
637      <para>
638       There was a hard-wired assumption that this system function was not
639       available on MIPS hardware on these systems.  Use a compile-time test
640       instead, since more recent versions have it.
641      </para>
642     </listitem>
643
644     <listitem>
645      <para>
646       Fix compilation failures on HP-UX (Heikki Linnakangas)
647      </para>
648     </listitem>
649
650     <listitem>
651      <para>
652       Fix path separator used by <application>pg_regress</> on Cygwin
653       (Andrew Dunstan)
654      </para>
655     </listitem>
656
657     <listitem>
658      <para>
659       Update time zone data files to <application>tzdata</> release 2011f
660       for DST law changes in Chile, Cuba, Falkland Islands, Morocco, Samoa,
661       and Turkey; also historical corrections for South Australia, Alaska,
662       and Hawaii.
663      </para>
664     </listitem>
665
666    </itemizedlist>
667
668   </sect2>
669  </sect1>
670
671  <sect1 id="release-8-2-20">
672   <title>Release 8.2.20</title>
673
674   <formalpara>
675   <title>Release date:</title>
676   <para>2011-01-31</para>
677   </formalpara>
678
679   <para>
680    This release contains a variety of fixes from 8.2.19.
681    For information about new features in the 8.2 major release, see
682    <xref linkend="release-8-2">.
683   </para>
684
685   <sect2>
686    <title>Migration to Version 8.2.20</title>
687
688    <para>
689     A dump/restore is not required for those running 8.2.X.
690     However, if you are upgrading from a version earlier than 8.2.14,
691     see <xref linkend="release-8-2-14">.
692    </para>
693
694   </sect2>
695
696   <sect2>
697    <title>Changes</title>
698
699    <itemizedlist>
700
701     <listitem>
702      <para>
703       Avoid failures when <command>EXPLAIN</> tries to display a simple-form
704       <literal>CASE</> expression (Tom Lane)
705      </para>
706
707      <para>
708       If the <literal>CASE</>'s test expression was a constant, the planner
709       could simplify the <literal>CASE</> into a form that confused the
710       expression-display code, resulting in <quote>unexpected CASE WHEN
711       clause</> errors.
712      </para>
713     </listitem>
714
715     <listitem>
716      <para>
717       Fix assignment to an array slice that is before the existing range
718       of subscripts (Tom Lane)
719      </para>
720
721      <para>
722       If there was a gap between the newly added subscripts and the first
723       pre-existing subscript, the code miscalculated how many entries needed
724       to be copied from the old array's null bitmap, potentially leading to
725       data corruption or crash.
726      </para>
727     </listitem>
728
729     <listitem>
730      <para>
731       Avoid unexpected conversion overflow in planner for very distant date
732       values (Tom Lane)
733      </para>
734
735      <para>
736       The <type>date</> type supports a wider range of dates than can be
737       represented by the <type>timestamp</> types, but the planner assumed it
738       could always convert a date to timestamp with impunity.
739      </para>
740     </listitem>
741
742     <listitem>
743      <para>
744       Fix <application>pg_restore</>'s text output for large objects (BLOBs)
745       when <varname>standard_conforming_strings</> is on (Tom Lane)
746      </para>
747
748      <para>
749       Although restoring directly to a database worked correctly, string
750       escaping was incorrect if <application>pg_restore</> was asked for
751       SQL text output and <varname>standard_conforming_strings</> had been
752       enabled in the source database.
753      </para>
754     </listitem>
755
756     <listitem>
757      <para>
758       Fix erroneous parsing of <type>tsquery</> values containing
759       <literal>... &amp; !(subexpression) | ...</literal> (Tom Lane)
760      </para>
761
762      <para>
763       Queries containing this combination of operators were not executed
764       correctly.  The same error existed in <filename>contrib/intarray</>'s
765       <type>query_int</> type and <filename>contrib/ltree</>'s
766       <type>ltxtquery</> type.
767      </para>
768     </listitem>
769
770     <listitem>
771      <para>
772       Fix buffer overrun in <filename>contrib/intarray</>'s input function
773       for the <type>query_int</> type (Apple)
774      </para>
775
776      <para>
777       This bug is a security risk since the function's return address could
778       be overwritten.  Thanks to Apple Inc's security team for reporting this
779       issue and supplying the fix.  (CVE-2010-4015)
780      </para>
781     </listitem>
782
783     <listitem>
784      <para>
785       Fix bug in <filename>contrib/seg</>'s GiST picksplit algorithm
786       (Alexander Korotkov)
787      </para>
788
789      <para>
790       This could result in considerable inefficiency, though not actually
791       incorrect answers, in a GiST index on a <type>seg</> column.
792       If you have such an index, consider <command>REINDEX</>ing it after
793       installing this update.  (This is identical to the bug that was fixed in
794       <filename>contrib/cube</> in the previous update.)
795      </para>
796     </listitem>
797
798    </itemizedlist>
799
800   </sect2>
801  </sect1>
802
803  <sect1 id="release-8-2-19">
804   <title>Release 8.2.19</title>
805
806   <formalpara>
807   <title>Release date:</title>
808   <para>2010-12-16</para>
809   </formalpara>
810
811   <para>
812    This release contains a variety of fixes from 8.2.18.
813    For information about new features in the 8.2 major release, see
814    <xref linkend="release-8-2">.
815   </para>
816
817   <sect2>
818    <title>Migration to Version 8.2.19</title>
819
820    <para>
821     A dump/restore is not required for those running 8.2.X.
822     However, if you are upgrading from a version earlier than 8.2.14,
823     see <xref linkend="release-8-2-14">.
824    </para>
825
826   </sect2>
827
828   <sect2>
829    <title>Changes</title>
830
831    <itemizedlist>
832
833     <listitem>
834      <para>
835       Force the default
836       <link linkend="guc-wal-sync-method"><varname>wal_sync_method</></link>
837       to be <literal>fdatasync</> on Linux (Tom Lane, Marti Raudsepp)
838      </para>
839
840      <para>
841       The default on Linux has actually been <literal>fdatasync</> for many
842       years, but recent kernel changes caused <productname>PostgreSQL</> to
843       choose <literal>open_datasync</> instead.  This choice did not result
844       in any performance improvement, and caused outright failures on
845       certain filesystems, notably <literal>ext4</> with the
846       <literal>data=journal</> mount option.
847      </para>
848     </listitem>
849
850     <listitem>
851      <para>
852       Fix assorted bugs in WAL replay logic for GIN indexes (Tom Lane)
853      </para>
854
855      <para>
856       This could result in <quote>bad buffer id: 0</> failures or
857       corruption of index contents during replication.
858      </para>
859     </listitem>
860
861     <listitem>
862      <para>
863       Fix recovery from base backup when the starting checkpoint WAL record
864       is not in the same WAL segment as its redo point (Jeff Davis)
865      </para>
866     </listitem>
867
868     <listitem>
869      <para>
870       Add support for detecting register-stack overrun on <literal>IA64</>
871       (Tom Lane)
872      </para>
873
874      <para>
875       The <literal>IA64</> architecture has two hardware stacks.  Full
876       prevention of stack-overrun failures requires checking both.
877      </para>
878     </listitem>
879
880     <listitem>
881      <para>
882       Add a check for stack overflow in <function>copyObject()</> (Tom Lane)
883      </para>
884
885      <para>
886       Certain code paths could crash due to stack overflow given a
887       sufficiently complex query.
888      </para>
889     </listitem>
890
891     <listitem>
892      <para>
893       Fix detection of page splits in temporary GiST indexes (Heikki
894       Linnakangas)
895      </para>
896
897      <para>
898       It is possible to have a <quote>concurrent</> page split in a
899       temporary index, if for example there is an open cursor scanning the
900       index when an insertion is done.  GiST failed to detect this case and
901       hence could deliver wrong results when execution of the cursor
902       continued.
903      </para>
904     </listitem>
905
906     <listitem>
907      <para>
908       Avoid memory leakage while <command>ANALYZE</>'ing complex index
909       expressions (Tom Lane)
910      </para>
911     </listitem>
912
913     <listitem>
914      <para>
915       Ensure an index that uses a whole-row Var still depends on its table
916       (Tom Lane)
917      </para>
918
919      <para>
920       An index declared like <literal>create index i on t (foo(t.*))</>
921       would not automatically get dropped when its table was dropped.
922      </para>
923     </listitem>
924
925     <listitem>
926      <para>
927       Do not <quote>inline</> a SQL function with multiple <literal>OUT</>
928       parameters (Tom Lane)
929      </para>
930
931      <para>
932       This avoids a possible crash due to loss of information about the
933       expected result rowtype.
934      </para>
935     </listitem>
936
937     <listitem>
938      <para>
939       Behave correctly if <literal>ORDER BY</>, <literal>LIMIT</>,
940       <literal>FOR UPDATE</>, or <literal>WITH</> is attached to the
941       <literal>VALUES</> part of <literal>INSERT ... VALUES</> (Tom Lane)
942      </para>
943     </listitem>
944
945     <listitem>
946      <para>
947       Fix constant-folding of <literal>COALESCE()</> expressions (Tom Lane)
948      </para>
949
950      <para>
951       The planner would sometimes attempt to evaluate sub-expressions that
952       in fact could never be reached, possibly leading to unexpected errors.
953      </para>
954     </listitem>
955
956     <listitem>
957      <para>
958       Add print functionality for <structname>InhRelation</> nodes (Tom Lane)
959      </para>
960
961      <para>
962       This avoids a failure when <varname>debug_print_parse</> is enabled
963       and certain types of query are executed.
964      </para>
965     </listitem>
966
967     <listitem>
968      <para>
969       Fix incorrect calculation of distance from a point to a horizontal
970       line segment (Tom Lane)
971      </para>
972
973      <para>
974       This bug affected several different geometric distance-measurement
975       operators.
976      </para>
977     </listitem>
978
979     <listitem>
980      <para>
981       Fix <application>PL/pgSQL</>'s handling of <quote>simple</>
982       expressions to not fail in recursion or error-recovery cases (Tom Lane)
983      </para>
984     </listitem>
985
986     <listitem>
987      <para>
988       Fix <application>PL/Python</>'s handling of set-returning functions
989       (Jan Urbanski)
990      </para>
991
992      <para>
993       Attempts to call SPI functions within the iterator generating a set
994       result would fail.
995      </para>
996     </listitem>
997
998     <listitem>
999      <para>
1000       Fix bug in <filename>contrib/cube</>'s GiST picksplit algorithm
1001       (Alexander Korotkov)
1002      </para>
1003
1004      <para>
1005       This could result in considerable inefficiency, though not actually
1006       incorrect answers, in a GiST index on a <type>cube</> column.
1007       If you have such an index, consider <command>REINDEX</>ing it after
1008       installing this update.
1009      </para>
1010     </listitem>
1011
1012     <listitem>
1013      <para>
1014       Don't emit <quote>identifier will be truncated</> notices in
1015       <filename>contrib/dblink</> except when creating new connections
1016       (Itagaki Takahiro)
1017      </para>
1018     </listitem>
1019
1020     <listitem>
1021      <para>
1022       Fix potential coredump on missing public key in
1023       <filename>contrib/pgcrypto</> (Marti Raudsepp)
1024      </para>
1025     </listitem>
1026
1027     <listitem>
1028      <para>
1029       Fix memory leak in <filename>contrib/xml2</>'s XPath query functions
1030       (Tom Lane)
1031      </para>
1032     </listitem>
1033
1034     <listitem>
1035      <para>
1036       Update time zone data files to <application>tzdata</> release 2010o
1037       for DST law changes in Fiji and Samoa;
1038       also historical corrections for Hong Kong.
1039      </para>
1040     </listitem>
1041
1042    </itemizedlist>
1043
1044   </sect2>
1045  </sect1>
1046
1047  <sect1 id="release-8-2-18">
1048   <title>Release 8.2.18</title>
1049
1050   <formalpara>
1051   <title>Release date:</title>
1052   <para>2010-10-04</para>
1053   </formalpara>
1054
1055   <para>
1056    This release contains a variety of fixes from 8.2.17.
1057    For information about new features in the 8.2 major release, see
1058    <xref linkend="release-8-2">.
1059   </para>
1060
1061   <sect2>
1062    <title>Migration to Version 8.2.18</title>
1063
1064    <para>
1065     A dump/restore is not required for those running 8.2.X.
1066     However, if you are upgrading from a version earlier than 8.2.14,
1067     see <xref linkend="release-8-2-14">.
1068    </para>
1069
1070   </sect2>
1071
1072   <sect2>
1073    <title>Changes</title>
1074
1075    <itemizedlist>
1076
1077     <listitem>
1078      <para>
1079       Use a separate interpreter for each calling SQL userid in PL/Perl and
1080       PL/Tcl (Tom Lane)
1081      </para>
1082
1083      <para>
1084       This change prevents security problems that can be caused by subverting
1085       Perl or Tcl code that will be executed later in the same session under
1086       another SQL user identity (for example, within a <literal>SECURITY
1087       DEFINER</> function).  Most scripting languages offer numerous ways that
1088       that might be done, such as redefining standard functions or operators
1089       called by the target function.  Without this change, any SQL user with
1090       Perl or Tcl language usage rights can do essentially anything with the
1091       SQL privileges of the target function's owner.
1092      </para>
1093
1094      <para>
1095       The cost of this change is that intentional communication among Perl
1096       and Tcl functions becomes more difficult.  To provide an escape hatch,
1097       PL/PerlU and PL/TclU functions continue to use only one interpreter
1098       per session.  This is not considered a security issue since all such
1099       functions execute at the trust level of a database superuser already.
1100      </para>
1101
1102      <para>
1103       It is likely that third-party procedural languages that claim to offer
1104       trusted execution have similar security issues.  We advise contacting
1105       the authors of any PL you are depending on for security-critical
1106       purposes.
1107      </para>
1108
1109      <para>
1110       Our thanks to Tim Bunce for pointing out this issue (CVE-2010-3433).
1111      </para>
1112     </listitem>
1113
1114     <listitem>
1115      <para>
1116       Prevent possible crashes in <function>pg_get_expr()</> by disallowing
1117       it from being called with an argument that is not one of the system
1118       catalog columns it's intended to be used with
1119       (Heikki Linnakangas, Tom Lane)
1120      </para>
1121     </listitem>
1122
1123     <listitem>
1124      <para>
1125       Fix Windows shared-memory allocation code
1126       (Tsutomu Yamada, Magnus Hagander)
1127      </para>
1128
1129      <para>
1130       This bug led to the often-reported <quote>could not reattach to shared
1131       memory</quote> error message.  This is a back-patch of a fix that was
1132       applied to newer branches some time ago.
1133      </para>
1134     </listitem>
1135
1136     <listitem>
1137      <para>
1138       Treat exit code 128 (<literal>ERROR_WAIT_NO_CHILDREN</>) as non-fatal on
1139       Windows (Magnus Hagander)
1140      </para>
1141
1142      <para>
1143       Under high load, Windows processes will sometimes fail at startup with
1144       this error code.  Formerly the postmaster treated this as a panic
1145       condition and restarted the whole database, but that seems to be
1146       an overreaction.
1147      </para>
1148     </listitem>
1149
1150     <listitem>
1151      <para>
1152       Fix possible duplicate scans of <literal>UNION ALL</> member relations
1153       (Tom Lane)
1154      </para>
1155     </listitem>
1156
1157     <listitem>
1158      <para>
1159       Fix <quote>cannot handle unplanned sub-select</quote> error (Tom Lane)
1160      </para>
1161
1162      <para>
1163       This occurred when a sub-select contains a join alias reference that
1164       expands into an expression containing another sub-select.
1165      </para>
1166     </listitem>
1167
1168     <listitem>
1169      <para>
1170       Reduce PANIC to ERROR in some occasionally-reported btree failure cases,
1171       and provide additional detail in the resulting error messages
1172       (Tom Lane)
1173      </para>
1174
1175      <para>
1176       This should improve the system's robustness with corrupted indexes.
1177      </para>
1178     </listitem>
1179
1180     <listitem>
1181      <para>
1182       Prevent show_session_authorization() from crashing within autovacuum
1183       processes (Tom Lane)
1184      </para>
1185     </listitem>
1186
1187     <listitem>
1188      <para>
1189       Defend against functions returning setof record where not all the
1190       returned rows are actually of the same rowtype (Tom Lane)
1191      </para>
1192     </listitem>
1193
1194     <listitem>
1195      <para>
1196       Fix possible failure when hashing a pass-by-reference function result
1197       (Tao Ma, Tom Lane)
1198      </para>
1199     </listitem>
1200
1201     <listitem>
1202      <para>
1203       Take care to fsync the contents of lockfiles (both
1204       <filename>postmaster.pid</> and the socket lockfile) while writing them
1205       (Tom Lane)
1206      </para>
1207
1208      <para>
1209       This omission could result in corrupted lockfile contents if the
1210       machine crashes shortly after postmaster start.  That could in turn
1211       prevent subsequent attempts to start the postmaster from succeeding,
1212       until the lockfile is manually removed.
1213      </para>
1214     </listitem>
1215
1216     <listitem>
1217      <para>
1218       Avoid recursion while assigning XIDs to heavily-nested
1219       subtransactions (Andres Freund, Robert Haas)
1220      </para>
1221
1222      <para>
1223       The original coding could result in a crash if there was limited
1224       stack space.
1225      </para>
1226     </listitem>
1227
1228     <listitem>
1229      <para>
1230       Fix <varname>log_line_prefix</>'s <literal>%i</> escape,
1231       which could produce junk early in backend startup (Tom Lane)
1232      </para>
1233     </listitem>
1234
1235     <listitem>
1236      <para>
1237       Fix possible data corruption in <command>ALTER TABLE ... SET
1238       TABLESPACE</> when archiving is enabled (Jeff Davis)
1239      </para>
1240     </listitem>
1241
1242     <listitem>
1243      <para>
1244       Allow <command>CREATE DATABASE</> and <command>ALTER DATABASE ... SET
1245       TABLESPACE</> to be interrupted by query-cancel (Guillaume Lelarge)
1246      </para>
1247     </listitem>
1248
1249     <listitem>
1250      <para>
1251       In PL/Python, defend against null pointer results from
1252       <function>PyCObject_AsVoidPtr</> and <function>PyCObject_FromVoidPtr</>
1253       (Peter Eisentraut)
1254      </para>
1255     </listitem>
1256
1257     <listitem>
1258      <para>
1259       Improve <filename>contrib/dblink</>'s handling of tables containing
1260       dropped columns (Tom Lane)
1261      </para>
1262     </listitem>
1263
1264     <listitem>
1265      <para>
1266       Fix connection leak after <quote>duplicate connection name</quote>
1267       errors in <filename>contrib/dblink</> (Itagaki Takahiro)
1268      </para>
1269     </listitem>
1270
1271     <listitem>
1272      <para>
1273       Fix <filename>contrib/dblink</> to handle connection names longer than
1274       62 bytes correctly (Itagaki Takahiro)
1275      </para>
1276     </listitem>
1277
1278     <listitem>
1279      <para>
1280       Add <function>hstore(text, text)</>
1281       function to <filename>contrib/hstore</> (Robert Haas)
1282      </para>
1283
1284      <para>
1285       This function is the recommended substitute for the now-deprecated
1286       <literal>=&gt;</> operator.  It was back-patched so that future-proofed
1287       code can be used with older server versions.  Note that the patch will
1288       be effective only after <filename>contrib/hstore</> is installed or
1289       reinstalled in a particular database.  Users might prefer to execute
1290       the <command>CREATE FUNCTION</> command by hand, instead.
1291      </para>
1292     </listitem>
1293
1294     <listitem>
1295      <para>
1296       Update build infrastructure and documentation to reflect the source code
1297       repository's move from CVS to Git (Magnus Hagander and others)
1298      </para>
1299     </listitem>
1300
1301     <listitem>
1302      <para>
1303       Update time zone data files to <application>tzdata</> release 2010l
1304       for DST law changes in Egypt and Palestine; also historical corrections
1305       for Finland.
1306      </para>
1307
1308      <para>
1309       This change also adds new names for two Micronesian timezones:
1310       Pacific/Chuuk is now preferred over Pacific/Truk (and the preferred
1311       abbreviation is CHUT not TRUT) and Pacific/Pohnpei is preferred over
1312       Pacific/Ponape.
1313      </para>
1314     </listitem>
1315
1316     <listitem>
1317      <para>
1318       Make Windows' <quote>N. Central Asia Standard Time</> timezone map to
1319       Asia/Novosibirsk, not Asia/Almaty (Magnus Hagander)
1320      </para>
1321
1322      <para>
1323       Microsoft changed the DST behavior of this zone in the timezone update
1324       from KB976098. Asia/Novosibirsk is a better match to its new behavior.
1325      </para>
1326     </listitem>
1327
1328    </itemizedlist>
1329
1330   </sect2>
1331  </sect1>
1332
1333  <sect1 id="release-8-2-17">
1334   <title>Release 8.2.17</title>
1335
1336   <formalpara>
1337   <title>Release date:</title>
1338   <para>2010-05-17</para>
1339   </formalpara>
1340
1341   <para>
1342    This release contains a variety of fixes from 8.2.16.
1343    For information about new features in the 8.2 major release, see
1344    <xref linkend="release-8-2">.
1345   </para>
1346
1347   <sect2>
1348    <title>Migration to Version 8.2.17</title>
1349
1350    <para>
1351     A dump/restore is not required for those running 8.2.X.
1352     However, if you are upgrading from a version earlier than 8.2.14,
1353     see <xref linkend="release-8-2-14">.
1354    </para>
1355
1356   </sect2>
1357
1358   <sect2>
1359    <title>Changes</title>
1360
1361    <itemizedlist>
1362
1363     <listitem>
1364      <para>
1365       Enforce restrictions in <literal>plperl</> using an opmask applied to
1366       the whole interpreter, instead of using <filename>Safe.pm</>
1367       (Tim Bunce, Andrew Dunstan)
1368      </para>
1369
1370      <para>
1371       Recent developments have convinced us that <filename>Safe.pm</> is too
1372       insecure to rely on for making <literal>plperl</> trustable.  This
1373       change removes use of <filename>Safe.pm</> altogether, in favor of using
1374       a separate interpreter with an opcode mask that is always applied.
1375       Pleasant side effects of the change include that it is now possible to
1376       use Perl's <literal>strict</> pragma in a natural way in
1377       <literal>plperl</>, and that Perl's <literal>$a</> and <literal>$b</>
1378       variables work as expected in sort routines, and that function
1379       compilation is significantly faster.  (CVE-2010-1169)
1380      </para>
1381     </listitem>
1382
1383     <listitem>
1384      <para>
1385       Prevent PL/Tcl from executing untrustworthy code from
1386       <structname>pltcl_modules</> (Tom)
1387      </para>
1388
1389      <para>
1390       PL/Tcl's feature for autoloading Tcl code from a database table
1391       could be exploited for trojan-horse attacks, because there was no
1392       restriction on who could create or insert into that table.  This change
1393       disables the feature unless <structname>pltcl_modules</> is owned by a
1394       superuser.  (However, the permissions on the table are not checked, so
1395       installations that really need a less-than-secure modules table can
1396       still grant suitable privileges to trusted non-superusers.)  Also,
1397       prevent loading code into the unrestricted <quote>normal</> Tcl
1398       interpreter unless we are really going to execute a <literal>pltclu</>
1399       function.  (CVE-2010-1170)
1400      </para>
1401     </listitem>
1402
1403     <listitem>
1404      <para>
1405       Fix possible crash if a cache reset message is received during
1406       rebuild of a relcache entry (Heikki)
1407      </para>
1408
1409      <para>
1410       This error was introduced in 8.2.16 while fixing a related failure.
1411      </para>
1412     </listitem>
1413
1414     <listitem>
1415      <para>
1416       Do not allow an unprivileged user to reset superuser-only parameter
1417       settings (Alvaro)
1418      </para>
1419
1420      <para>
1421       Previously, if an unprivileged user ran <literal>ALTER USER ... RESET
1422       ALL</> for himself, or <literal>ALTER DATABASE ... RESET ALL</> for
1423       a database he owns, this would remove all special parameter settings
1424       for the user or database, even ones that are only supposed to be
1425       changeable by a superuser.  Now, the <command>ALTER</> will only
1426       remove the parameters that the user has permission to change.
1427      </para>
1428     </listitem>
1429
1430     <listitem>
1431      <para>
1432       Avoid possible crash during backend shutdown if shutdown occurs
1433       when a <literal>CONTEXT</> addition would be made to log entries (Tom)
1434      </para>
1435
1436      <para>
1437       In some cases the context-printing function would fail because the
1438       current transaction had already been rolled back when it came time
1439       to print a log message.
1440      </para>
1441     </listitem>
1442
1443     <listitem>
1444      <para>
1445       Update PL/Perl's <filename>ppport.h</> for modern Perl versions
1446       (Andrew)
1447      </para>
1448     </listitem>
1449
1450     <listitem>
1451      <para>
1452       Fix assorted memory leaks in PL/Python (Andreas Freund, Tom)
1453      </para>
1454     </listitem>
1455
1456     <listitem>
1457      <para>
1458       Prevent infinite recursion in <application>psql</> when expanding
1459       a variable that refers to itself (Tom)
1460      </para>
1461     </listitem>
1462
1463     <listitem>
1464      <para>
1465       Fix <application>psql</>'s <literal>\copy</> to not add spaces around
1466       a dot within <literal>\copy (select ...)</> (Tom)
1467      </para>
1468
1469      <para>
1470       Addition of spaces around the decimal point in a numeric literal would
1471       result in a syntax error.
1472      </para>
1473     </listitem>
1474
1475     <listitem>
1476      <para>
1477       Ensure that <filename>contrib/pgstattuple</> functions respond to cancel
1478       interrupts promptly (Tatsuhito Kasahara)
1479      </para>
1480     </listitem>
1481
1482     <listitem>
1483      <para>
1484       Make server startup deal properly with the case that
1485       <function>shmget()</> returns <literal>EINVAL</> for an existing
1486       shared memory segment (Tom)
1487      </para>
1488
1489      <para>
1490       This behavior has been observed on BSD-derived kernels including macOS.
1491       It resulted in an entirely-misleading startup failure complaining that
1492       the shared memory request size was too large.
1493      </para>
1494     </listitem>
1495
1496     <listitem>
1497      <para>
1498       Avoid possible crashes in syslogger process on Windows (Heikki)
1499      </para>
1500     </listitem>
1501
1502     <listitem>
1503      <para>
1504       Deal more robustly with incomplete time zone information in the
1505       Windows registry (Magnus)
1506      </para>
1507     </listitem>
1508
1509     <listitem>
1510      <para>
1511       Update the set of known Windows time zone names (Magnus)
1512      </para>
1513     </listitem>
1514
1515     <listitem>
1516      <para>
1517       Update time zone data files to <application>tzdata</> release 2010j
1518       for DST law changes in Argentina, Australian Antarctic, Bangladesh,
1519       Mexico, Morocco, Pakistan, Palestine, Russia, Syria, Tunisia;
1520       also historical corrections for Taiwan.
1521      </para>
1522
1523      <para>
1524       Also, add <literal>PKST</> (Pakistan Summer Time) to the default set of
1525       timezone abbreviations.
1526      </para>
1527     </listitem>
1528
1529    </itemizedlist>
1530
1531   </sect2>
1532  </sect1>
1533
1534  <sect1 id="release-8-2-16">
1535   <title>Release 8.2.16</title>
1536
1537   <formalpara>
1538   <title>Release date:</title>
1539   <para>2010-03-15</para>
1540   </formalpara>
1541
1542   <para>
1543    This release contains a variety of fixes from 8.2.15.
1544    For information about new features in the 8.2 major release, see
1545    <xref linkend="release-8-2">.
1546   </para>
1547
1548   <sect2>
1549    <title>Migration to Version 8.2.16</title>
1550
1551    <para>
1552     A dump/restore is not required for those running 8.2.X.
1553     However, if you are upgrading from a version earlier than 8.2.14,
1554     see <xref linkend="release-8-2-14">.
1555    </para>
1556
1557   </sect2>
1558
1559   <sect2>
1560    <title>Changes</title>
1561
1562    <itemizedlist>
1563
1564     <listitem>
1565      <para>
1566       Add new configuration parameter <varname>ssl_renegotiation_limit</> to
1567       control how often we do session key renegotiation for an SSL connection
1568       (Magnus)
1569      </para>
1570
1571      <para>
1572       This can be set to zero to disable renegotiation completely, which may
1573       be required if a broken SSL library is used.  In particular, some
1574       vendors are shipping stopgap patches for CVE-2009-3555 that cause
1575       renegotiation attempts to fail.
1576      </para>
1577     </listitem>
1578
1579     <listitem>
1580      <para>
1581       Fix possible deadlock during backend startup (Tom)
1582      </para>
1583     </listitem>
1584
1585     <listitem>
1586      <para>
1587       Fix possible crashes due to not handling errors during relcache reload
1588       cleanly (Tom)
1589      </para>
1590     </listitem>
1591
1592     <listitem>
1593      <para>
1594       Fix possible crashes when trying to recover from a failure in
1595       subtransaction start (Tom)
1596      </para>
1597     </listitem>
1598
1599     <listitem>
1600      <para>
1601       Fix server memory leak associated with use of savepoints and a client
1602       encoding different from server's encoding (Tom)
1603      </para>
1604     </listitem>
1605
1606     <listitem>
1607      <para>
1608       Fix incorrect WAL data emitted during end-of-recovery cleanup of a GIST
1609       index page split (Yoichi Hirai)
1610      </para>
1611
1612      <para>
1613       This would result in index corruption, or even more likely an error
1614       during WAL replay, if we were unlucky enough to crash during
1615       end-of-recovery cleanup after having completed an incomplete GIST
1616       insertion.
1617      </para>
1618     </listitem>
1619
1620     <listitem>
1621      <para>
1622       Make <function>substring()</> for <type>bit</> types treat any negative
1623       length as meaning <quote>all the rest of the string</> (Tom)
1624      </para>
1625
1626      <para>
1627       The previous coding treated only -1 that way, and would produce an
1628       invalid result value for other negative values, possibly leading to
1629       a crash (CVE-2010-0442).
1630      </para>
1631     </listitem>
1632
1633     <listitem>
1634      <para>
1635       Fix integer-to-bit-string conversions to handle the first fractional
1636       byte correctly when the output bit width is wider than the given
1637       integer by something other than a multiple of 8 bits (Tom)
1638      </para>
1639     </listitem>
1640
1641     <listitem>
1642      <para>
1643       Fix some cases of pathologically slow regular expression matching (Tom)
1644      </para>
1645     </listitem>
1646
1647     <listitem>
1648      <para>
1649       Fix the <literal>STOP WAL LOCATION</> entry in backup history files to
1650       report the next WAL segment's name when the end location is exactly at a
1651       segment boundary (Itagaki Takahiro)
1652      </para>
1653     </listitem>
1654
1655     <listitem>
1656      <para>
1657       Fix some more cases of temporary-file leakage (Heikki)
1658      </para>
1659
1660      <para>
1661       This corrects a problem introduced in the previous minor release.
1662       One case that failed is when a plpgsql function returning set is
1663       called within another function's exception handler.
1664      </para>
1665     </listitem>
1666
1667     <listitem>
1668      <para>
1669       Improve constraint exclusion processing of boolean-variable cases,
1670       in particular make it possible to exclude a partition that has a
1671       <quote>bool_column = false</> constraint (Tom)
1672      </para>
1673     </listitem>
1674
1675     <listitem>
1676      <para>
1677       When reading <filename>pg_hba.conf</> and related files, do not treat
1678       <literal>@something</> as a file inclusion request if the <literal>@</>
1679       appears inside quote marks; also, never treat <literal>@</> by itself
1680       as a file inclusion request (Tom)
1681      </para>
1682
1683      <para>
1684       This prevents erratic behavior if a role or database name starts with
1685       <literal>@</>.  If you need to include a file whose path name
1686       contains spaces, you can still do so, but you must write
1687       <literal>@"/path to/file"</> rather than putting the quotes around
1688       the whole construct.
1689      </para>
1690     </listitem>
1691
1692     <listitem>
1693      <para>
1694       Prevent infinite loop on some platforms if a directory is named as
1695       an inclusion target in <filename>pg_hba.conf</> and related files
1696       (Tom)
1697      </para>
1698     </listitem>
1699
1700     <listitem>
1701      <para>
1702       Fix possible infinite loop if <function>SSL_read</> or
1703       <function>SSL_write</> fails without setting <varname>errno</> (Tom)
1704      </para>
1705
1706      <para>
1707       This is reportedly possible with some Windows versions of
1708       <application>openssl</>.
1709      </para>
1710     </listitem>
1711
1712     <listitem>
1713      <para>
1714       Fix <application>psql</>'s <literal>numericlocale</> option to not
1715       format strings it shouldn't in latex and troff output formats (Heikki)
1716      </para>
1717     </listitem>
1718
1719     <listitem>
1720      <para>
1721       Make <application>psql</> return the correct exit status (3) when
1722       <literal>ON_ERROR_STOP</> and <literal>--single-transaction</> are
1723       both specified and an error occurs during the implied <command>COMMIT</>
1724       (Bruce)
1725      </para>
1726     </listitem>
1727
1728     <listitem>
1729      <para>
1730       Fix plpgsql failure in one case where a composite column is set to NULL
1731       (Tom)
1732      </para>
1733     </listitem>
1734
1735     <listitem>
1736      <para>
1737       Fix possible failure when calling PL/Perl functions from PL/PerlU
1738       or vice versa (Tim Bunce)
1739      </para>
1740     </listitem>
1741
1742     <listitem>
1743      <para>
1744       Add <literal>volatile</> markings in PL/Python to avoid possible
1745       compiler-specific misbehavior (Zdenek Kotala)
1746      </para>
1747     </listitem>
1748
1749     <listitem>
1750      <para>
1751       Ensure PL/Tcl initializes the Tcl interpreter fully (Tom)
1752      </para>
1753
1754      <para>
1755       The only known symptom of this oversight is that the Tcl
1756       <literal>clock</> command misbehaves if using Tcl 8.5 or later.
1757      </para>
1758     </listitem>
1759
1760     <listitem>
1761      <para>
1762       Prevent crash in <filename>contrib/dblink</> when too many key
1763       columns are specified to a <function>dblink_build_sql_*</> function
1764       (Rushabh Lathia, Joe Conway)
1765      </para>
1766     </listitem>
1767
1768     <listitem>
1769      <para>
1770       Fix assorted crashes in <filename>contrib/xml2</> caused by sloppy
1771       memory management (Tom)
1772      </para>
1773     </listitem>
1774
1775     <listitem>
1776      <para>
1777       Make building of <filename>contrib/xml2</> more robust on Windows
1778       (Andrew)
1779      </para>
1780     </listitem>
1781
1782     <listitem>
1783      <para>
1784       Fix race condition in Windows signal handling (Radu Ilie)
1785      </para>
1786
1787      <para>
1788       One known symptom of this bug is that rows in <structname>pg_listener</>
1789       could be dropped under heavy load.
1790      </para>
1791     </listitem>
1792
1793     <listitem>
1794      <para>
1795       Update time zone data files to <application>tzdata</> release 2010e
1796       for DST law changes in Bangladesh, Chile, Fiji, Mexico, Paraguay, Samoa.
1797      </para>
1798     </listitem>
1799
1800    </itemizedlist>
1801
1802   </sect2>
1803  </sect1>
1804
1805  <sect1 id="release-8-2-15">
1806   <title>Release 8.2.15</title>
1807
1808   <formalpara>
1809   <title>Release date:</title>
1810   <para>2009-12-14</para>
1811   </formalpara>
1812
1813   <para>
1814    This release contains a variety of fixes from 8.2.14.
1815    For information about new features in the 8.2 major release, see
1816    <xref linkend="release-8-2">.
1817   </para>
1818
1819   <sect2>
1820    <title>Migration to Version 8.2.15</title>
1821
1822    <para>
1823     A dump/restore is not required for those running 8.2.X.
1824     However, if you are upgrading from a version earlier than 8.2.14,
1825     see <xref linkend="release-8-2-14">.
1826    </para>
1827
1828   </sect2>
1829
1830   <sect2>
1831    <title>Changes</title>
1832
1833    <itemizedlist>
1834
1835     <listitem>
1836      <para>
1837       Protect against indirect security threats caused by index functions
1838       changing session-local state (Gurjeet Singh, Tom)
1839      </para>
1840
1841      <para>
1842       This change prevents allegedly-immutable index functions from possibly
1843       subverting a superuser's session (CVE-2009-4136).
1844      </para>
1845     </listitem>
1846
1847     <listitem>
1848      <para>
1849       Reject SSL certificates containing an embedded null byte in the common
1850       name (CN) field (Magnus)
1851      </para>
1852
1853      <para>
1854       This prevents unintended matching of a certificate to a server or client
1855       name during SSL validation (CVE-2009-4034).
1856      </para>
1857     </listitem>
1858
1859     <listitem>
1860      <para>
1861       Fix possible crash during backend-startup-time cache initialization (Tom)
1862      </para>
1863     </listitem>
1864
1865     <listitem>
1866      <para>
1867       Prevent signals from interrupting <literal>VACUUM</> at unsafe times
1868       (Alvaro)
1869      </para>
1870
1871      <para>
1872       This fix prevents a PANIC if a <literal>VACUUM FULL</> is canceled
1873       after it's already committed its tuple movements, as well as transient
1874       errors if a plain <literal>VACUUM</> is interrupted after having
1875       truncated the table.
1876      </para>
1877     </listitem>
1878
1879     <listitem>
1880      <para>
1881       Fix possible crash due to integer overflow in hash table size
1882       calculation (Tom)
1883      </para>
1884
1885      <para>
1886       This could occur with extremely large planner estimates for the size of
1887       a hashjoin's result.
1888      </para>
1889     </listitem>
1890
1891     <listitem>
1892      <para>
1893       Fix very rare crash in <type>inet</>/<type>cidr</> comparisons (Chris
1894       Mikkelson)
1895      </para>
1896     </listitem>
1897
1898     <listitem>
1899      <para>
1900       Ensure that shared tuple-level locks held by prepared transactions are
1901       not ignored (Heikki)
1902      </para>
1903     </listitem>
1904
1905     <listitem>
1906      <para>
1907       Fix premature drop of temporary files used for a cursor that is accessed
1908       within a subtransaction (Heikki)
1909      </para>
1910     </listitem>
1911
1912     <listitem>
1913      <para>
1914       Fix incorrect logic for GiST index page splits, when the split depends
1915       on a non-first column of the index (Paul Ramsey)
1916      </para>
1917     </listitem>
1918
1919     <listitem>
1920      <para>
1921       Don't error out if recycling or removing an old WAL file fails at the
1922       end of checkpoint (Heikki)
1923      </para>
1924
1925      <para>
1926       It's better to treat the problem as non-fatal and allow the checkpoint
1927       to complete.  Future checkpoints will retry the removal.  Such problems
1928       are not expected in normal operation, but have been seen to be
1929       caused by misdesigned Windows anti-virus and backup software.
1930      </para>
1931     </listitem>
1932
1933     <listitem>
1934      <para>
1935       Ensure WAL files aren't repeatedly archived on Windows (Heikki)
1936      </para>
1937
1938      <para>
1939       This is another symptom that could happen if some other process
1940       interfered with deletion of a no-longer-needed file.
1941      </para>
1942     </listitem>
1943
1944     <listitem>
1945      <para>
1946       Fix PAM password processing to be more robust (Tom)
1947      </para>
1948
1949      <para>
1950       The previous code is known to fail with the combination of the Linux
1951       <literal>pam_krb5</> PAM module with Microsoft Active Directory as the
1952       domain controller.  It might have problems elsewhere too, since it was
1953       making unjustified assumptions about what arguments the PAM stack would
1954       pass to it.
1955      </para>
1956     </listitem>
1957
1958     <listitem>
1959      <para>
1960       Fix processing of ownership dependencies during <literal>CREATE OR
1961       REPLACE FUNCTION</> (Tom)
1962      </para>
1963     </listitem>
1964
1965     <listitem>
1966      <para>
1967       Fix bug with calling <literal>plperl</> from <literal>plperlu</> or vice
1968       versa (Tom)
1969      </para>
1970
1971      <para>
1972       An error exit from the inner function could result in crashes due to
1973       failure to re-select the correct Perl interpreter for the outer function.
1974      </para>
1975     </listitem>
1976
1977     <listitem>
1978      <para>
1979       Fix session-lifespan memory leak when a PL/Perl function is redefined
1980       (Tom)
1981      </para>
1982     </listitem>
1983
1984     <listitem>
1985      <para>
1986       Ensure that Perl arrays are properly converted to
1987       <productname>PostgreSQL</> arrays when returned by a set-returning
1988       PL/Perl function (Andrew Dunstan, Abhijit Menon-Sen)
1989      </para>
1990
1991      <para>
1992       This worked correctly already for non-set-returning functions.
1993      </para>
1994     </listitem>
1995
1996     <listitem>
1997      <para>
1998       Fix rare crash in exception processing in PL/Python (Peter)
1999      </para>
2000     </listitem>
2001
2002     <listitem>
2003      <para>
2004       Ensure <application>psql</>'s flex module is compiled with the correct
2005       system header definitions (Tom)
2006      </para>
2007
2008      <para>
2009       This fixes build failures on platforms where
2010       <literal>--enable-largefile</> causes incompatible changes in the
2011       generated code.
2012      </para>
2013     </listitem>
2014
2015     <listitem>
2016      <para>
2017       Make the postmaster ignore any <literal>application_name</> parameter in
2018       connection request packets, to improve compatibility with future libpq
2019       versions (Tom)
2020      </para>
2021     </listitem>
2022
2023     <listitem>
2024      <para>
2025       Update the timezone abbreviation files to match current reality (Joachim
2026       Wieland)
2027      </para>
2028
2029      <para>
2030       This includes adding <literal>IDT</> and <literal>SGT</> to the default
2031       timezone abbreviation set.
2032      </para>
2033     </listitem>
2034
2035     <listitem>
2036      <para>
2037       Update time zone data files to <application>tzdata</> release 2009s
2038       for DST law changes in Antarctica, Argentina, Bangladesh, Fiji,
2039       Novokuznetsk, Pakistan, Palestine, Samoa, Syria; also historical
2040       corrections for Hong Kong.
2041      </para>
2042     </listitem>
2043
2044    </itemizedlist>
2045
2046   </sect2>
2047  </sect1>
2048
2049  <sect1 id="release-8-2-14">
2050   <title>Release 8.2.14</title>
2051
2052   <formalpara>
2053   <title>Release date:</title>
2054   <para>2009-09-09</para>
2055   </formalpara>
2056
2057   <para>
2058    This release contains a variety of fixes from 8.2.13.
2059    For information about new features in the 8.2 major release, see
2060    <xref linkend="release-8-2">.
2061   </para>
2062
2063   <sect2>
2064    <title>Migration to Version 8.2.14</title>
2065
2066    <para>
2067     A dump/restore is not required for those running 8.2.X.
2068     However, if you have any hash indexes on <type>interval</> columns,
2069     you must <command>REINDEX</> them after updating to 8.2.14.
2070     Also, if you are upgrading from a version earlier than 8.2.11,
2071     see <xref linkend="release-8-2-11">.
2072    </para>
2073
2074   </sect2>
2075
2076   <sect2>
2077    <title>Changes</title>
2078
2079    <itemizedlist>
2080
2081     <listitem>
2082      <para>
2083       Force WAL segment switch during <function>pg_start_backup()</>
2084       (Heikki)
2085      </para>
2086
2087      <para>
2088       This avoids corner cases that could render a base backup unusable.
2089      </para>
2090     </listitem>
2091
2092     <listitem>
2093      <para>
2094       Disallow <command>RESET ROLE</> and <command>RESET SESSION
2095       AUTHORIZATION</> inside security-definer functions (Tom, Heikki)
2096      </para>
2097
2098      <para>
2099       This covers a case that was missed in the previous patch that
2100       disallowed <command>SET ROLE</> and <command>SET SESSION
2101       AUTHORIZATION</> inside security-definer functions.
2102       (See CVE-2007-6600)
2103      </para>
2104     </listitem>
2105
2106     <listitem>
2107      <para>
2108       Make <command>LOAD</> of an already-loaded loadable module
2109       into a no-op (Tom)
2110      </para>
2111
2112      <para>
2113       Formerly, <command>LOAD</> would attempt to unload and re-load the
2114       module, but this is unsafe and not all that useful.
2115      </para>
2116     </listitem>
2117
2118     <listitem>
2119      <para>
2120       Disallow empty passwords during LDAP authentication (Magnus)
2121      </para>
2122     </listitem>
2123
2124     <listitem>
2125      <para>
2126       Fix handling of sub-SELECTs appearing in the arguments of
2127       an outer-level aggregate function (Tom)
2128      </para>
2129     </listitem>
2130
2131     <listitem>
2132      <para>
2133       Fix bugs associated with fetching a whole-row value from the
2134       output of a Sort or Materialize plan node (Tom)
2135      </para>
2136     </listitem>
2137
2138     <listitem>
2139      <para>
2140       Revert planner change that disabled partial-index and constraint
2141       exclusion optimizations when there were more than 100 clauses in
2142       an AND or OR list (Tom)
2143      </para>
2144     </listitem>
2145
2146     <listitem>
2147      <para>
2148       Fix hash calculation for data type <type>interval</> (Tom)
2149      </para>
2150
2151      <para>
2152       This corrects wrong results for hash joins on interval values.
2153       It also changes the contents of hash indexes on interval columns.
2154       If you have any such indexes, you must <command>REINDEX</> them
2155       after updating.
2156      </para>
2157     </listitem>
2158
2159     <listitem>
2160      <para>
2161       Treat <function>to_char(..., 'TH')</> as an uppercase ordinal
2162       suffix with <literal>'HH'</>/<literal>'HH12'</> (Heikki)
2163      </para>
2164
2165      <para>
2166       It was previously handled as <literal>'th'</> (lowercase).
2167      </para>
2168     </listitem>
2169
2170     <listitem>
2171      <para>
2172       Fix overflow for <literal>INTERVAL '<replaceable>x</> ms'</literal>
2173       when <replaceable>x</> is more than 2 million and integer
2174       datetimes are in use (Alex Hunsaker)
2175      </para>
2176     </listitem>
2177
2178     <listitem>
2179      <para>
2180       Fix calculation of distance between a point and a line segment (Tom)
2181      </para>
2182
2183      <para>
2184       This led to incorrect results from a number of geometric operators.
2185      </para>
2186     </listitem>
2187
2188     <listitem>
2189      <para>
2190       Fix <type>money</> data type to work in locales where currency
2191       amounts have no fractional digits, e.g. Japan (Itagaki Takahiro)
2192      </para>
2193     </listitem>
2194
2195     <listitem>
2196      <para>
2197       Properly round datetime input like
2198       <literal>00:12:57.9999999999999999999999999999</> (Tom)
2199      </para>
2200     </listitem>
2201
2202     <listitem>
2203      <para>
2204       Fix poor choice of page split point in GiST R-tree operator classes
2205       (Teodor)
2206      </para>
2207     </listitem>
2208
2209     <listitem>
2210      <para>
2211       Avoid performance degradation in bulk inserts into GIN indexes
2212       when the input values are (nearly) in sorted order (Tom)
2213      </para>
2214     </listitem>
2215
2216     <listitem>
2217      <para>
2218       Correctly enforce NOT NULL domain constraints in some contexts in
2219       PL/pgSQL (Tom)
2220      </para>
2221     </listitem>
2222
2223     <listitem>
2224      <para>
2225       Fix portability issues in plperl initialization (Andrew Dunstan)
2226      </para>
2227     </listitem>
2228
2229     <listitem>
2230      <para>
2231       Fix <application>pg_ctl</> to not go into an infinite loop if
2232       <filename>postgresql.conf</> is empty (Jeff Davis)
2233      </para>
2234     </listitem>
2235
2236     <listitem>
2237      <para>
2238       Make <filename>contrib/hstore</> throw an error when a key or
2239       value is too long to fit in its data structure, rather than
2240       silently truncating it (Andrew Gierth)
2241      </para>
2242     </listitem>
2243
2244     <listitem>
2245      <para>
2246       Fix <filename>contrib/xml2</>'s <function>xslt_process()</> to
2247       properly handle the maximum number of parameters (twenty) (Tom)
2248      </para>
2249     </listitem>
2250
2251     <listitem>
2252      <para>
2253       Improve robustness of <application>libpq</>'s code to recover
2254       from errors during <command>COPY FROM STDIN</> (Tom)
2255      </para>
2256     </listitem>
2257
2258     <listitem>
2259      <para>
2260       Avoid including conflicting readline and editline header files
2261       when both libraries are installed (Zdenek Kotala)
2262      </para>
2263     </listitem>
2264
2265     <listitem>
2266      <para>
2267       Update time zone data files to <application>tzdata</> release 2009l
2268       for DST law changes in Bangladesh, Egypt, Jordan, Pakistan,
2269       Argentina/San_Luis, Cuba, Jordan (historical correction only),
2270       Mauritius, Morocco, Palestine, Syria, Tunisia.
2271      </para>
2272     </listitem>
2273
2274    </itemizedlist>
2275
2276   </sect2>
2277  </sect1>
2278
2279  <sect1 id="release-8-2-13">
2280   <title>Release 8.2.13</title>
2281
2282   <formalpara>
2283   <title>Release date:</title>
2284   <para>2009-03-16</para>
2285   </formalpara>
2286
2287   <para>
2288    This release contains a variety of fixes from 8.2.12.
2289    For information about new features in the 8.2 major release, see
2290    <xref linkend="release-8-2">.
2291   </para>
2292
2293   <sect2>
2294    <title>Migration to Version 8.2.13</title>
2295
2296    <para>
2297     A dump/restore is not required for those running 8.2.X.
2298     However, if you are upgrading from a version earlier than 8.2.11,
2299     see <xref linkend="release-8-2-11">.
2300    </para>
2301
2302   </sect2>
2303
2304   <sect2>
2305    <title>Changes</title>
2306
2307    <itemizedlist>
2308
2309     <listitem>
2310      <para>
2311       Prevent error recursion crashes when encoding conversion fails (Tom)
2312      </para>
2313
2314      <para>
2315       This change extends fixes made in the last two minor releases for
2316       related failure scenarios.  The previous fixes were narrowly tailored
2317       for the original problem reports, but we have now recognized that
2318       <emphasis>any</> error thrown by an encoding conversion function could
2319       potentially lead to infinite recursion while trying to report the
2320       error.  The solution therefore is to disable translation and encoding
2321       conversion and report the plain-ASCII form of any error message,
2322       if we find we have gotten into a recursive error reporting situation.
2323       (CVE-2009-0922)
2324      </para>
2325     </listitem>
2326
2327     <listitem>
2328      <para>
2329       Disallow <command>CREATE CONVERSION</> with the wrong encodings
2330       for the specified conversion function (Heikki)
2331      </para>
2332
2333      <para>
2334       This prevents one possible scenario for encoding conversion failure.
2335       The previous change is a backstop to guard against other kinds of
2336       failures in the same area.
2337      </para>
2338     </listitem>
2339
2340     <listitem>
2341      <para>
2342       Fix core dump when <function>to_char()</> is given format codes that
2343       are inappropriate for the type of the data argument (Tom)
2344      </para>
2345     </listitem>
2346
2347     <listitem>
2348      <para>
2349       Fix possible failure in <filename>contrib/tsearch2</> when C locale is
2350       used with a multi-byte encoding (Teodor)
2351      </para>
2352
2353      <para>
2354       Crashes were possible on platforms where <type>wchar_t</> is narrower
2355       than <type>int</>; Windows in particular.
2356      </para>
2357     </listitem>
2358
2359     <listitem>
2360      <para>
2361       Fix extreme inefficiency in <filename>contrib/tsearch2</> parser's
2362       handling of an email-like string containing multiple <literal>@</>
2363       characters (Heikki)
2364      </para>
2365     </listitem>
2366
2367     <listitem>
2368      <para>
2369       Fix decompilation of <literal>CASE WHEN</> with an implicit coercion
2370       (Tom)
2371      </para>
2372
2373      <para>
2374       This mistake could lead to Assert failures in an Assert-enabled build,
2375       or an <quote>unexpected CASE WHEN clause</> error message in other
2376       cases, when trying to examine or dump a view.
2377      </para>
2378     </listitem>
2379
2380     <listitem>
2381      <para>
2382       Fix possible misassignment of the owner of a TOAST table's rowtype (Tom)
2383      </para>
2384
2385      <para>
2386       If <command>CLUSTER</> or a rewriting variant of <command>ALTER TABLE</>
2387       were executed by someone other than the table owner, the
2388       <structname>pg_type</> entry for the table's TOAST table would end up
2389       marked as owned by that someone.  This caused no immediate problems,
2390       since the permissions on the TOAST rowtype aren't examined by any
2391       ordinary database operation.  However, it could lead to unexpected
2392       failures if one later tried to drop the role that issued the command
2393       (in 8.1 or 8.2), or <quote>owner of data type appears to be invalid</>
2394       warnings from <application>pg_dump</> after having done so (in 8.3).
2395      </para>
2396     </listitem>
2397
2398     <listitem>
2399      <para>
2400       Fix PL/pgSQL to not treat <literal>INTO</> after <command>INSERT</> as
2401       an INTO-variables clause anywhere in the string, not only at the start;
2402       in particular, don't fail for <command>INSERT INTO</> within
2403       <command>CREATE RULE</> (Tom)
2404      </para>
2405     </listitem>
2406
2407     <listitem>
2408      <para>
2409       Clean up PL/pgSQL error status variables fully at block exit
2410       (Ashesh Vashi and Dave Page)
2411      </para>
2412
2413      <para>
2414       This is not a problem for PL/pgSQL itself, but the omission could cause
2415       the PL/pgSQL Debugger to crash while examining the state of a function.
2416      </para>
2417     </listitem>
2418
2419     <listitem>
2420      <para>
2421       Retry failed calls to <function>CallNamedPipe()</> on Windows
2422       (Steve Marshall, Magnus)
2423      </para>
2424
2425      <para>
2426       It appears that this function can sometimes fail transiently;
2427       we previously treated any failure as a hard error, which could
2428       confuse <command>LISTEN</>/<command>NOTIFY</> as well as other
2429       operations.
2430      </para>
2431     </listitem>
2432
2433     <listitem>
2434      <para>
2435       Add <literal>MUST</> (Mauritius Island Summer Time) to the default list
2436       of known timezone abbreviations (Xavier Bugaud)
2437      </para>
2438     </listitem>
2439
2440    </itemizedlist>
2441
2442   </sect2>
2443  </sect1>
2444
2445  <sect1 id="release-8-2-12">
2446   <title>Release 8.2.12</title>
2447
2448   <formalpara>
2449   <title>Release date:</title>
2450   <para>2009-02-02</para>
2451   </formalpara>
2452
2453   <para>
2454    This release contains a variety of fixes from 8.2.11.
2455    For information about new features in the 8.2 major release, see
2456    <xref linkend="release-8-2">.
2457   </para>
2458
2459   <sect2>
2460    <title>Migration to Version 8.2.12</title>
2461
2462    <para>
2463     A dump/restore is not required for those running 8.2.X.
2464     However, if you are upgrading from a version earlier than 8.2.11,
2465     see <xref linkend="release-8-2-11">.
2466    </para>
2467
2468   </sect2>
2469
2470   <sect2>
2471    <title>Changes</title>
2472
2473    <itemizedlist>
2474
2475     <listitem>
2476      <para>
2477       Improve handling of URLs in <function>headline()</> function (Teodor)
2478      </para>
2479     </listitem>
2480
2481     <listitem>
2482      <para>
2483       Improve handling of overlength headlines in <function>headline()</>
2484       function (Teodor)
2485      </para>
2486     </listitem>
2487
2488     <listitem>
2489      <para>
2490       Prevent possible Assert failure or misconversion if an encoding
2491       conversion is created with the wrong conversion function for the
2492       specified pair of encodings (Tom, Heikki)
2493      </para>
2494     </listitem>
2495
2496     <listitem>
2497      <para>
2498       Fix possible Assert failure if a statement executed in PL/pgSQL is
2499       rewritten into another kind of statement, for example if an
2500       <command>INSERT</> is rewritten into an <command>UPDATE</> (Heikki)
2501      </para>
2502     </listitem>
2503
2504     <listitem>
2505      <para>
2506       Ensure that a snapshot is available to datatype input functions (Tom)
2507      </para>
2508
2509      <para>
2510       This primarily affects domains that are declared with <literal>CHECK</>
2511       constraints involving user-defined stable or immutable functions.  Such
2512       functions typically fail if no snapshot has been set.
2513      </para>
2514     </listitem>
2515
2516     <listitem>
2517      <para>
2518       Make it safer for SPI-using functions to be used within datatype I/O;
2519       in particular, to be used in domain check constraints (Tom)
2520      </para>
2521     </listitem>
2522
2523     <listitem>
2524      <para>
2525       Avoid unnecessary locking of small tables in <command>VACUUM</>
2526       (Heikki)
2527      </para>
2528     </listitem>
2529
2530     <listitem>
2531      <para>
2532       Fix a problem that made <literal>UPDATE RETURNING tableoid</>
2533       return zero instead of the correct OID (Tom)
2534      </para>
2535     </listitem>
2536
2537     <listitem>
2538      <para>
2539       Fix planner misestimation of selectivity when transitive equality
2540       is applied to an outer-join clause (Tom)
2541      </para>
2542
2543      <para>
2544       This could result in bad plans for queries like
2545       <literal>... from a left join b on a.a1 = b.b1 where a.a1 = 42 ...</>
2546      </para>
2547     </listitem>
2548
2549     <listitem>
2550      <para>
2551       Improve optimizer's handling of long <literal>IN</> lists (Tom)
2552      </para>
2553
2554      <para>
2555       This change avoids wasting large amounts of time on such lists
2556       when constraint exclusion is enabled.
2557      </para>
2558     </listitem>
2559
2560     <listitem>
2561      <para>
2562       Ensure that the contents of a holdable cursor don't depend on the
2563       contents of TOAST tables (Tom)
2564      </para>
2565
2566      <para>
2567       Previously, large field values in a cursor result might be represented
2568       as TOAST pointers, which would fail if the referenced table got dropped
2569       before the cursor is read, or if the large value is deleted and then
2570       vacuumed away.  This cannot happen with an ordinary cursor,
2571       but it could with a cursor that is held past its creating transaction.
2572      </para>
2573     </listitem>
2574
2575     <listitem>
2576      <para>
2577       Fix memory leak when a set-returning function is terminated without
2578       reading its whole result (Tom)
2579      </para>
2580     </listitem>
2581
2582     <listitem>
2583      <para>
2584       Fix <filename>contrib/dblink</>'s
2585       <function>dblink_get_result(text,bool)</> function (Joe)
2586      </para>
2587     </listitem>
2588
2589     <listitem>
2590      <para>
2591       Fix possible garbage output from <filename>contrib/sslinfo</> functions
2592       (Tom)
2593      </para>
2594     </listitem>
2595
2596     <listitem>
2597      <para>
2598       Fix <application>configure</> script to properly report failure when
2599       unable to obtain linkage information for PL/Perl (Andrew)
2600      </para>
2601     </listitem>
2602
2603     <listitem>
2604      <para>
2605       Make all documentation reference <literal>pgsql-bugs</> and/or
2606       <literal>pgsql-hackers</> as appropriate, instead of the
2607       now-decommissioned <literal>pgsql-ports</> and <literal>pgsql-patches</>
2608       mailing lists (Tom)
2609      </para>
2610     </listitem>
2611
2612     <listitem>
2613      <para>
2614       Update time zone data files to <application>tzdata</> release 2009a (for
2615       Kathmandu and historical DST corrections in Switzerland, Cuba)
2616      </para>
2617     </listitem>
2618
2619    </itemizedlist>
2620
2621   </sect2>
2622  </sect1>
2623
2624  <sect1 id="release-8-2-11">
2625   <title>Release 8.2.11</title>
2626
2627   <formalpara>
2628   <title>Release date:</title>
2629   <para>2008-11-03</para>
2630   </formalpara>
2631
2632   <para>
2633    This release contains a variety of fixes from 8.2.10.
2634    For information about new features in the 8.2 major release, see
2635    <xref linkend="release-8-2">.
2636   </para>
2637
2638   <sect2>
2639    <title>Migration to Version 8.2.11</title>
2640
2641    <para>
2642     A dump/restore is not required for those running 8.2.X.
2643     However, if you are upgrading from a version earlier than 8.2.7,
2644     see <xref linkend="release-8-2-7">.  Also, if you were running a previous
2645     8.2.X release, it is recommended to <command>REINDEX</> all GiST
2646     indexes after the upgrade.
2647    </para>
2648
2649   </sect2>
2650
2651   <sect2>
2652    <title>Changes</title>
2653
2654    <itemizedlist>
2655
2656     <listitem>
2657      <para>
2658       Fix GiST index corruption due to marking the wrong index entry
2659       <quote>dead</> after a deletion (Teodor)
2660      </para>
2661
2662      <para>
2663       This would result in index searches failing to find rows they
2664       should have found.  Corrupted indexes can be fixed with
2665       <command>REINDEX</>.
2666      </para>
2667     </listitem>
2668
2669     <listitem>
2670      <para>
2671       Fix backend crash when the client encoding cannot represent a localized
2672       error message (Tom)
2673      </para>
2674
2675      <para>
2676       We have addressed similar issues before, but it would still fail if
2677       the <quote>character has no equivalent</> message itself couldn't
2678       be converted.  The fix is to disable localization and send the plain
2679       ASCII error message when we detect such a situation.
2680      </para>
2681     </listitem>
2682
2683     <listitem>
2684      <para>
2685       Fix possible crash when deeply nested functions are invoked from
2686       a trigger (Tom)
2687      </para>
2688     </listitem>
2689
2690     <listitem>
2691      <para>
2692       Improve optimization of <replaceable>expression</> <literal>IN</>
2693       (<replaceable>expression-list</>) queries (Tom, per an idea from Robert
2694       Haas)
2695      </para>
2696
2697      <para>
2698       Cases in which there are query variables on the right-hand side had been
2699       handled less efficiently in 8.2.x and 8.3.x than in prior versions.
2700       The fix restores 8.1 behavior for such cases.
2701      </para>
2702     </listitem>
2703
2704     <listitem>
2705      <para>
2706       Fix mis-expansion of rule queries when a sub-<literal>SELECT</> appears
2707       in a function call in <literal>FROM</>,  a multi-row <literal>VALUES</>
2708       list, or a <literal>RETURNING</> list (Tom)
2709      </para>
2710
2711      <para>
2712       The usual symptom of this problem is an <quote>unrecognized node type</>
2713       error.
2714      </para>
2715     </listitem>
2716
2717     <listitem>
2718      <para>
2719       Fix memory leak during rescan of a hashed aggregation plan (Neil)
2720      </para>
2721     </listitem>
2722
2723     <listitem>
2724      <para>
2725       Ensure an error is reported when a newly-defined PL/pgSQL trigger
2726       function is invoked as a normal function (Tom)
2727      </para>
2728     </listitem>
2729
2730     <listitem>
2731      <para>
2732       Prevent possible collision of <structfield>relfilenode</> numbers
2733       when moving a table to another tablespace with <command>ALTER SET
2734       TABLESPACE</> (Heikki)
2735      </para>
2736
2737      <para>
2738       The command tried to re-use the existing filename, instead of
2739       picking one that is known unused in the destination directory.
2740      </para>
2741     </listitem>
2742
2743     <listitem>
2744      <para>
2745       Fix incorrect tsearch2 headline generation when single query
2746       item matches first word of text (Sushant Sinha)
2747      </para>
2748     </listitem>
2749
2750     <listitem>
2751      <para>
2752       Fix improper display of fractional seconds in interval values when
2753       using a non-ISO datestyle in an <option>--enable-integer-datetimes</>
2754       build (Ron Mayer)
2755      </para>
2756     </listitem>
2757
2758     <listitem>
2759      <para>
2760       Ensure <function>SPI_getvalue</> and <function>SPI_getbinval</>
2761       behave correctly when the passed tuple and tuple descriptor have
2762       different numbers of columns (Tom)
2763      </para>
2764
2765      <para>
2766       This situation is normal when a table has had columns added or removed,
2767       but these two functions didn't handle it properly.
2768       The only likely consequence is an incorrect error indication.
2769      </para>
2770     </listitem>
2771
2772     <listitem>
2773      <para>
2774       Fix <application>ecpg</>'s parsing of <command>CREATE ROLE</> (Michael)
2775      </para>
2776     </listitem>
2777
2778     <listitem>
2779      <para>
2780       Fix recent breakage of <literal>pg_ctl restart</> (Tom)
2781      </para>
2782     </listitem>
2783
2784     <listitem>
2785      <para>
2786       Ensure <filename>pg_control</> is opened in binary mode
2787       (Itagaki Takahiro)
2788      </para>
2789
2790      <para>
2791       <application>pg_controldata</> and <application>pg_resetxlog</>
2792       did this incorrectly, and so could fail on Windows.
2793      </para>
2794     </listitem>
2795
2796     <listitem>
2797      <para>
2798       Update time zone data files to <application>tzdata</> release 2008i (for
2799       DST law changes in Argentina, Brazil, Mauritius, Syria)
2800      </para>
2801     </listitem>
2802
2803    </itemizedlist>
2804
2805   </sect2>
2806  </sect1>
2807
2808  <sect1 id="release-8-2-10">
2809   <title>Release 8.2.10</title>
2810
2811   <formalpara>
2812   <title>Release date:</title>
2813   <para>2008-09-22</para>
2814   </formalpara>
2815
2816   <para>
2817    This release contains a variety of fixes from 8.2.9.
2818    For information about new features in the 8.2 major release, see
2819    <xref linkend="release-8-2">.
2820   </para>
2821
2822   <sect2>
2823    <title>Migration to Version 8.2.10</title>
2824
2825    <para>
2826     A dump/restore is not required for those running 8.2.X.
2827     However, if you are upgrading from a version earlier than 8.2.7,
2828     see <xref linkend="release-8-2-7">.
2829    </para>
2830
2831   </sect2>
2832
2833   <sect2>
2834    <title>Changes</title>
2835
2836    <itemizedlist>
2837
2838     <listitem>
2839      <para>
2840       Fix bug in btree WAL recovery code (Heikki)
2841      </para>
2842
2843      <para>
2844       Recovery failed if the WAL ended partway through a page split operation.
2845      </para>
2846     </listitem>
2847
2848     <listitem>
2849      <para>
2850       Fix potential miscalculation of <structfield>datfrozenxid</> (Alvaro)
2851      </para>
2852
2853      <para>
2854       This error may explain some recent reports of failure to remove old
2855       <structname>pg_clog</> data.
2856      </para>
2857     </listitem>
2858
2859     <listitem>
2860      <para>
2861       Widen local lock counters from 32 to 64 bits (Tom)
2862      </para>
2863
2864      <para>
2865       This responds to reports that the counters could overflow in
2866       sufficiently long transactions, leading to unexpected <quote>lock is
2867       already held</> errors.
2868      </para>
2869     </listitem>
2870
2871     <listitem>
2872      <para>
2873       Fix possible duplicate output of tuples during a GiST index scan (Teodor)
2874      </para>
2875     </listitem>
2876
2877     <listitem>
2878      <para>
2879       Fix missed permissions checks when a view contains a simple
2880       <literal>UNION ALL</> construct (Heikki)
2881      </para>
2882
2883      <para>
2884       Permissions for the referenced tables were checked properly, but not
2885       permissions for the view itself.
2886      </para>
2887     </listitem>
2888
2889     <listitem>
2890      <para>
2891       Add checks in executor startup to ensure that the tuples produced by an
2892       <command>INSERT</> or <command>UPDATE</> will match the target table's
2893       current rowtype (Tom)
2894      </para>
2895
2896      <para>
2897       <command>ALTER COLUMN TYPE</>, followed by re-use of a previously
2898       cached plan, could produce this type of situation.  The check protects
2899       against data corruption and/or crashes that could ensue.
2900      </para>
2901     </listitem>
2902
2903     <listitem>
2904      <para>
2905       Fix possible repeated drops during <command>DROP OWNED</> (Tom)
2906      </para>
2907
2908      <para>
2909       This would typically result in strange errors such as <quote>cache
2910       lookup failed for relation NNN</>.
2911      </para>
2912     </listitem>
2913
2914     <listitem>
2915      <para>
2916       Fix <literal>AT TIME ZONE</> to first try to interpret its timezone
2917       argument as a timezone abbreviation, and only try it as a full timezone
2918       name if that fails, rather than the other way around as formerly (Tom)
2919      </para>
2920
2921      <para>
2922       The timestamp input functions have always resolved ambiguous zone names
2923       in this order.  Making <literal>AT TIME ZONE</> do so as well improves
2924       consistency, and fixes a compatibility bug introduced in 8.1:
2925       in ambiguous cases we now behave the same as 8.0 and before did,
2926       since in the older versions <literal>AT TIME ZONE</> accepted
2927       <emphasis>only</> abbreviations.
2928      </para>
2929     </listitem>
2930
2931     <listitem>
2932      <para>
2933       Fix datetime input functions to correctly detect integer overflow when
2934       running on a 64-bit platform (Tom)
2935      </para>
2936     </listitem>
2937
2938     <listitem>
2939      <para>
2940       Prevent integer overflows during units conversion when displaying a
2941       configuration parameter that has units (Tom)
2942      </para>
2943     </listitem>
2944
2945     <listitem>
2946      <para>
2947       Improve performance of writing very long log messages to syslog (Tom)
2948      </para>
2949     </listitem>
2950
2951     <listitem>
2952      <para>
2953       Allow spaces in the suffix part of an LDAP URL in
2954       <filename>pg_hba.conf</> (Tom)
2955      </para>
2956     </listitem>
2957
2958     <listitem>
2959      <para>
2960       Fix bug in backwards scanning of a cursor on a <literal>SELECT DISTINCT
2961       ON</> query (Tom)
2962      </para>
2963     </listitem>
2964
2965     <listitem>
2966      <para>
2967       Fix planner bug with nested sub-select expressions (Tom)
2968      </para>
2969
2970      <para>
2971       If the outer sub-select has no direct dependency on the parent query,
2972       but the inner one does, the outer value might not get recalculated
2973       for new parent query rows.
2974      </para>
2975     </listitem>
2976
2977     <listitem>
2978      <para>
2979       Fix planner to estimate that <literal>GROUP BY</> expressions yielding
2980       boolean results always result in two groups, regardless of the
2981       expressions' contents (Tom)
2982      </para>
2983
2984      <para>
2985       This is very substantially more accurate than the regular <literal>GROUP
2986       BY</> estimate for certain boolean tests like <replaceable>col</>
2987       <literal>IS NULL</>.
2988      </para>
2989     </listitem>
2990
2991     <listitem>
2992      <para>
2993       Fix PL/pgSQL to not fail when a <literal>FOR</> loop's target variable
2994       is a record containing composite-type fields (Tom)
2995      </para>
2996     </listitem>
2997
2998     <listitem>
2999      <para>
3000       Fix PL/Tcl to behave correctly with Tcl 8.5, and to be more careful
3001       about the encoding of data sent to or from Tcl (Tom)
3002      </para>
3003     </listitem>
3004
3005     <listitem>
3006      <para>
3007       On Windows, work around a Microsoft bug by preventing
3008       <application>libpq</> from trying to send more than 64kB per system call
3009       (Magnus)
3010      </para>
3011     </listitem>
3012
3013     <listitem>
3014      <para>
3015       Improve <application>pg_dump</> and <application>pg_restore</>'s
3016       error reporting after failure to send a SQL command (Tom)
3017      </para>
3018     </listitem>
3019
3020     <listitem>
3021      <para>
3022       Fix <application>pg_ctl</> to properly preserve postmaster
3023       command-line arguments across a <literal>restart</> (Bruce)
3024      </para>
3025     </listitem>
3026
3027     <listitem>
3028      <para>
3029       Update time zone data files to <application>tzdata</> release 2008f (for
3030       DST law changes in Argentina, Bahamas, Brazil, Mauritius, Morocco,
3031       Pakistan, Palestine, and Paraguay)
3032      </para>
3033     </listitem>
3034
3035    </itemizedlist>
3036
3037   </sect2>
3038  </sect1>
3039
3040  <sect1 id="release-8-2-9">
3041   <title>Release 8.2.9</title>
3042
3043   <formalpara>
3044   <title>Release date:</title>
3045   <para>2008-06-12</para>
3046   </formalpara>
3047
3048   <para>
3049    This release contains one serious and one minor bug fix over 8.2.8.
3050    For information about new features in the 8.2 major release, see
3051    <xref linkend="release-8-2">.
3052   </para>
3053
3054   <sect2>
3055    <title>Migration to Version 8.2.9</title>
3056
3057    <para>
3058     A dump/restore is not required for those running 8.2.X.
3059     However, if you are upgrading from a version earlier than 8.2.7,
3060     see <xref linkend="release-8-2-7">.
3061    </para>
3062
3063   </sect2>
3064
3065   <sect2>
3066    <title>Changes</title>
3067
3068    <itemizedlist>
3069
3070     <listitem>
3071      <para>
3072       Make <function>pg_get_ruledef()</> parenthesize negative constants (Tom)
3073      </para>
3074
3075      <para>
3076       Before this fix, a negative constant in a view or rule might be dumped
3077       as, say, <literal>-42::integer</>, which is subtly incorrect: it should
3078       be <literal>(-42)::integer</> due to operator precedence rules.
3079       Usually this would make little difference, but it could interact with
3080       another recent patch to cause
3081       <productname>PostgreSQL</> to reject what had been a valid
3082       <command>SELECT DISTINCT</> view query.  Since this could result in
3083       <application>pg_dump</> output failing to reload, it is being treated
3084       as a high-priority fix.  The only released versions in which dump
3085       output is actually incorrect are 8.3.1 and 8.2.7.
3086      </para>
3087     </listitem>
3088
3089     <listitem>
3090      <para>
3091       Make <command>ALTER AGGREGATE ... OWNER TO</> update
3092       <structname>pg_shdepend</> (Tom)
3093      </para>
3094
3095      <para>
3096       This oversight could lead to problems if the aggregate was later
3097       involved in a <command>DROP OWNED</> or <command>REASSIGN OWNED</>
3098       operation.
3099      </para>
3100     </listitem>
3101
3102    </itemizedlist>
3103
3104   </sect2>
3105  </sect1>
3106
3107  <sect1 id="release-8-2-8">
3108   <title>Release 8.2.8</title>
3109
3110   <formalpara>
3111   <title>Release date:</title>
3112   <para>never released</para>
3113   </formalpara>
3114
3115   <para>
3116    This release contains a variety of fixes from 8.2.7.
3117    For information about new features in the 8.2 major release, see
3118    <xref linkend="release-8-2">.
3119   </para>
3120
3121   <sect2>
3122    <title>Migration to Version 8.2.8</title>
3123
3124    <para>
3125     A dump/restore is not required for those running 8.2.X.
3126     However, if you are upgrading from a version earlier than 8.2.7,
3127     see <xref linkend="release-8-2-7">.
3128    </para>
3129
3130   </sect2>
3131
3132   <sect2>
3133    <title>Changes</title>
3134
3135    <itemizedlist>
3136
3137     <listitem>
3138      <para>
3139       Fix <literal>ERRORDATA_STACK_SIZE exceeded</literal> crash that
3140       occurred on Windows when using UTF-8 database encoding and a different
3141       client encoding (Tom)
3142      </para>
3143     </listitem>
3144
3145     <listitem>
3146      <para>
3147       Fix <command>ALTER TABLE ADD COLUMN ... PRIMARY KEY</> so that the new
3148       column is correctly checked to see if it's been initialized to all
3149       non-nulls (Brendan Jurd)
3150      </para>
3151
3152      <para>
3153       Previous versions neglected to check this requirement at all.
3154      </para>
3155     </listitem>
3156
3157     <listitem>
3158      <para>
3159       Fix possible <command>CREATE TABLE</> failure when inheriting the
3160       <quote>same</> constraint from multiple parent relations that
3161       inherited that constraint from a common ancestor (Tom)
3162      </para>
3163     </listitem>
3164
3165     <listitem>
3166      <para>
3167       Fix <function>pg_get_ruledef()</> to show the alias, if any, attached
3168       to the target table of an <command>UPDATE</> or <command>DELETE</>
3169       (Tom)
3170      </para>
3171     </listitem>
3172
3173     <listitem>
3174      <para>
3175       Fix GIN bug that could result in a <literal>too many LWLocks
3176       taken</literal> failure (Teodor)
3177      </para>
3178     </listitem>
3179
3180     <listitem>
3181      <para>
3182       Avoid possible crash when decompressing corrupted data
3183       (Zdenek Kotala)
3184      </para>
3185     </listitem>
3186
3187     <listitem>
3188      <para>
3189       Repair two places where SIGTERM exit of a backend could leave corrupted
3190       state in shared memory (Tom)
3191      </para>
3192
3193      <para>
3194       Neither case is very important if SIGTERM is used to shut down the
3195       whole database cluster together, but there was a problem if someone
3196       tried to SIGTERM individual backends.
3197      </para>
3198     </listitem>
3199
3200     <listitem>
3201      <para>
3202       Fix conversions between ISO-8859-5 and other encodings to handle
3203       Cyrillic <quote>Yo</> characters (<literal>e</> and <literal>E</> with
3204       two dots) (Sergey Burladyan)
3205      </para>
3206     </listitem>
3207
3208     <listitem>
3209      <para>
3210       Fix several datatype input functions, notably <function>array_in()</>,
3211       that were allowing unused bytes in their results to contain
3212       uninitialized, unpredictable values (Tom)
3213      </para>
3214
3215      <para>
3216       This could lead to failures in which two apparently identical literal
3217       values were not seen as equal, resulting in the parser complaining
3218       about unmatched <literal>ORDER BY</> and <literal>DISTINCT</>
3219       expressions.
3220      </para>
3221     </listitem>
3222
3223     <listitem>
3224      <para>
3225       Fix a corner case in regular-expression substring matching
3226       (<literal>substring(<replaceable>string</> from
3227       <replaceable>pattern</>)</literal>) (Tom)
3228      </para>
3229
3230      <para>
3231       The problem occurs when there is a match to the pattern overall but
3232       the user has specified a parenthesized subexpression and that
3233       subexpression hasn't got a match.  An example is
3234       <literal>substring('foo' from 'foo(bar)?')</>.
3235       This should return NULL, since <literal>(bar)</> isn't matched, but
3236       it was mistakenly returning the whole-pattern match instead (ie,
3237       <literal>foo</>).
3238      </para>
3239     </listitem>
3240
3241     <listitem>
3242      <para>
3243       Update time zone data files to <application>tzdata</> release 2008c (for
3244       DST law changes in Morocco, Iraq, Choibalsan, Pakistan, Syria, Cuba, and
3245       Argentina/San_Luis)
3246      </para>
3247     </listitem>
3248
3249     <listitem>
3250      <para>
3251       Fix incorrect result from <application>ecpg</>'s
3252       <function>PGTYPEStimestamp_sub()</> function (Michael)
3253      </para>
3254     </listitem>
3255
3256     <listitem>
3257      <para>
3258       Fix broken GiST comparison function for <filename>contrib/tsearch2</>'s
3259       <type>tsquery</> type (Teodor)
3260      </para>
3261     </listitem>
3262
3263     <listitem>
3264      <para>
3265       Fix possible crashes in <filename>contrib/cube</> functions (Tom)
3266      </para>
3267     </listitem>
3268
3269     <listitem>
3270      <para>
3271       Fix core dump in <filename>contrib/xml2</>'s
3272       <function>xpath_table()</> function when the input query returns a
3273       NULL value (Tom)
3274      </para>
3275     </listitem>
3276
3277     <listitem>
3278      <para>
3279       Fix <filename>contrib/xml2</>'s makefile to not override
3280       <literal>CFLAGS</> (Tom)
3281      </para>
3282     </listitem>
3283
3284     <listitem>
3285      <para>
3286       Fix <literal>DatumGetBool</> macro to not fail with <application>gcc</>
3287       4.3 (Tom)
3288      </para>
3289
3290      <para>
3291       This problem affects <quote>old style</> (V0) C functions that
3292       return boolean.  The fix is already in 8.3, but the need to
3293       back-patch it was not realized at the time.
3294      </para>
3295     </listitem>
3296
3297    </itemizedlist>
3298
3299   </sect2>
3300  </sect1>
3301
3302  <sect1 id="release-8-2-7">
3303   <title>Release 8.2.7</title>
3304
3305   <formalpara>
3306   <title>Release date:</title>
3307   <para>2008-03-17</para>
3308   </formalpara>
3309
3310   <para>
3311    This release contains a variety of fixes from 8.2.6.
3312    For information about new features in the 8.2 major release, see
3313    <xref linkend="release-8-2">.
3314   </para>
3315
3316   <sect2>
3317    <title>Migration to Version 8.2.7</title>
3318
3319    <para>
3320     A dump/restore is not required for those running 8.2.X.
3321     However, you might need to <command>REINDEX</> indexes on textual
3322     columns after updating, if you are affected by the Windows locale
3323     issue described below.
3324    </para>
3325
3326   </sect2>
3327
3328   <sect2>
3329    <title>Changes</title>
3330
3331    <itemizedlist>
3332
3333     <listitem>
3334      <para>
3335       Fix character string comparison for Windows locales that consider
3336       different character combinations as equal (Tom)
3337      </para>
3338
3339      <para>
3340       This fix applies only on Windows and only when using UTF-8
3341       database encoding.  The same fix was made for all other cases
3342       over two years ago, but Windows with UTF-8 uses a separate code
3343       path that was not updated.  If you are using a locale that
3344       considers some non-identical strings as equal, you may need to
3345       <command>REINDEX</> to fix existing indexes on textual columns.
3346      </para>
3347     </listitem>
3348
3349     <listitem>
3350      <para>
3351       Repair potential deadlock between concurrent <command>VACUUM FULL</>
3352       operations on different system catalogs (Tom)
3353      </para>
3354     </listitem>
3355
3356     <listitem>
3357      <para>
3358       Fix longstanding <command>LISTEN</>/<command>NOTIFY</>
3359       race condition (Tom)
3360      </para>
3361
3362      <para>
3363       In rare cases a session that had just executed a
3364       <command>LISTEN</> might not get a notification, even though
3365       one would be expected because the concurrent transaction executing
3366       <command>NOTIFY</> was observed to commit later.
3367      </para>
3368
3369      <para>
3370       A side effect of the fix is that a transaction that has executed
3371       a not-yet-committed <command>LISTEN</> command will not see any
3372       row in <structname>pg_listener</> for the <command>LISTEN</>,
3373       should it choose to look; formerly it would have.  This behavior
3374       was never documented one way or the other, but it is possible that
3375       some applications depend on the old behavior.
3376      </para>
3377     </listitem>
3378
3379     <listitem>
3380      <para>
3381       Disallow <command>LISTEN</> and <command>UNLISTEN</> within a
3382       prepared transaction (Tom)
3383      </para>
3384
3385      <para>
3386       This was formerly allowed but trying to do it had various unpleasant
3387       consequences, notably that the originating backend could not exit
3388       as long as an <command>UNLISTEN</> remained uncommitted.
3389      </para>
3390     </listitem>
3391
3392     <listitem>
3393      <para>
3394       Disallow dropping a temporary table within a
3395       prepared transaction (Heikki)
3396      </para>
3397
3398      <para>
3399       This was correctly disallowed by 8.1, but the check was inadvertently
3400       broken in 8.2.
3401      </para>
3402     </listitem>
3403
3404     <listitem>
3405      <para>
3406       Fix rare crash when an error occurs during a query using a hash index
3407       (Heikki)
3408      </para>
3409     </listitem>
3410
3411     <listitem>
3412      <para>
3413       Fix memory leaks in certain usages of set-returning functions (Neil)
3414      </para>
3415     </listitem>
3416
3417     <listitem>
3418      <para>
3419       Fix input of datetime values for February 29 in years BC (Tom)
3420      </para>
3421
3422      <para>
3423       The former coding was mistaken about which years were leap years.
3424      </para>
3425     </listitem>
3426
3427     <listitem>
3428      <para>
3429       Fix <quote>unrecognized node type</> error in some variants of
3430       <command>ALTER OWNER</> (Tom)
3431      </para>
3432     </listitem>
3433
3434     <listitem>
3435      <para>
3436       Ensure <structname>pg_stat_activity</>.<structfield>waiting</> flag
3437       is cleared when a lock wait is aborted (Tom)
3438      </para>
3439     </listitem>
3440
3441     <listitem>
3442      <para>
3443       Fix handling of process permissions on Windows Vista (Dave, Magnus)
3444      </para>
3445
3446      <para>
3447       In particular, this fix allows starting the server as the Administrator
3448       user.
3449      </para>
3450     </listitem>
3451
3452     <listitem>
3453      <para>
3454       Update time zone data files to <application>tzdata</> release 2008a
3455       (in particular, recent Chile changes); adjust timezone abbreviation
3456       <literal>VET</> (Venezuela) to mean UTC-4:30, not UTC-4:00 (Tom)
3457      </para>
3458     </listitem>
3459
3460     <listitem>
3461      <para>
3462       Fix <application>pg_ctl</> to correctly extract the postmaster's port
3463       number from command-line options (Itagaki Takahiro, Tom)
3464      </para>
3465
3466      <para>
3467       Previously, <literal>pg_ctl start -w</> could try to contact the
3468       postmaster on the wrong port, leading to bogus reports of startup
3469       failure.
3470      </para>
3471     </listitem>
3472
3473     <listitem>
3474      <para>
3475       Use <option>-fwrapv</> to defend against possible misoptimization
3476       in recent <application>gcc</> versions (Tom)
3477      </para>
3478
3479      <para>
3480       This is known to be necessary when building <productname>PostgreSQL</>
3481       with <application>gcc</> 4.3 or later.
3482      </para>
3483     </listitem>
3484
3485
3486     <listitem>
3487      <para>
3488       Correctly enforce <varname>statement_timeout</> values longer
3489       than <literal>INT_MAX</> microseconds (about 35 minutes) (Tom)
3490      </para>
3491
3492      <para>
3493       This bug affects only builds with <option>--enable-integer-datetimes</>.
3494      </para>
3495     </listitem>
3496
3497     <listitem>
3498      <para>
3499       Fix <quote>unexpected PARAM_SUBLINK ID</> planner error when
3500       constant-folding simplifies a sub-select (Tom)
3501      </para>
3502     </listitem>
3503
3504     <listitem>
3505      <para>
3506       Fix logical errors in constraint-exclusion handling of <literal>IS
3507       NULL</> and <literal>NOT</> expressions (Tom)
3508      </para>
3509
3510      <para>
3511       The planner would sometimes exclude partitions that should not
3512       have been excluded because of the possibility of NULL results.
3513      </para>
3514     </listitem>
3515
3516     <listitem>
3517      <para>
3518       Fix another cause of <quote>failed to build any N-way joins</>
3519       planner errors (Tom)
3520      </para>
3521
3522      <para>
3523       This could happen in cases where a clauseless join needed to be
3524       forced before a join clause could be exploited.
3525      </para>
3526     </listitem>
3527
3528     <listitem>
3529      <para>
3530       Fix incorrect constant propagation in outer-join planning (Tom)
3531      </para>
3532
3533      <para>
3534       The planner could sometimes incorrectly conclude that a variable
3535       could be constrained to be equal to a constant, leading
3536       to wrong query results.
3537      </para>
3538     </listitem>
3539
3540     <listitem>
3541      <para>
3542       Fix display of constant expressions in <literal>ORDER BY</>
3543       and <literal>GROUP BY</> (Tom)
3544      </para>
3545
3546      <para>
3547       An explicitly casted constant would be shown incorrectly.  This could
3548       for example lead to corruption of a view definition during
3549       dump and reload.
3550      </para>
3551     </listitem>
3552
3553     <listitem>
3554      <para>
3555       Fix <application>libpq</> to handle NOTICE messages correctly
3556       during COPY OUT (Tom)
3557      </para>
3558
3559      <para>
3560       This failure has only been observed to occur when a user-defined
3561       datatype's output routine issues a NOTICE, but there is no
3562       guarantee it couldn't happen due to other causes.
3563      </para>
3564     </listitem>
3565
3566    </itemizedlist>
3567
3568   </sect2>
3569  </sect1>
3570
3571  <sect1 id="release-8-2-6">
3572   <title>Release 8.2.6</title>
3573
3574   <formalpara>
3575   <title>Release date:</title>
3576   <para>2008-01-07</para>
3577   </formalpara>
3578
3579   <para>
3580    This release contains a variety of fixes from 8.2.5,
3581    including fixes for significant security issues.
3582    For information about new features in the 8.2 major release, see
3583    <xref linkend="release-8-2">.
3584   </para>
3585
3586   <sect2>
3587    <title>Migration to Version 8.2.6</title>
3588
3589    <para>
3590     A dump/restore is not required for those running 8.2.X.
3591    </para>
3592
3593   </sect2>
3594
3595   <sect2>
3596    <title>Changes</title>
3597
3598    <itemizedlist>
3599
3600     <listitem>
3601      <para>
3602       Prevent functions in indexes from executing with the privileges of
3603       the user running <command>VACUUM</>, <command>ANALYZE</>, etc (Tom)
3604      </para>
3605
3606      <para>
3607       Functions used in index expressions and partial-index
3608       predicates are evaluated whenever a new table entry is made.  It has
3609       long been understood that this poses a risk of trojan-horse code
3610       execution if one modifies a table owned by an untrustworthy user.
3611       (Note that triggers, defaults, check constraints, etc. pose the
3612       same type of risk.)  But functions in indexes pose extra danger
3613       because they will be executed by routine maintenance operations
3614       such as <command>VACUUM FULL</>, which are commonly performed
3615       automatically under a superuser account.  For example, a nefarious user
3616       can execute code with superuser privileges by setting up a
3617       trojan-horse index definition and waiting for the next routine vacuum.
3618       The fix arranges for standard maintenance operations
3619       (including <command>VACUUM</>, <command>ANALYZE</>, <command>REINDEX</>,
3620       and <command>CLUSTER</>) to execute as the table owner rather than
3621       the calling user, using the same privilege-switching mechanism already
3622       used for <literal>SECURITY DEFINER</> functions.  To prevent bypassing
3623       this security measure, execution of <command>SET SESSION
3624       AUTHORIZATION</> and <command>SET ROLE</> is now forbidden within a
3625       <literal>SECURITY DEFINER</> context.  (CVE-2007-6600)
3626      </para>
3627     </listitem>
3628
3629     <listitem>
3630      <para>
3631       Repair assorted bugs in the regular-expression package (Tom, Will Drewry)
3632      </para>
3633
3634      <para>
3635       Suitably crafted regular-expression patterns could cause crashes,
3636       infinite or near-infinite looping, and/or massive memory consumption,
3637       all of which pose denial-of-service hazards for applications that
3638       accept regex search patterns from untrustworthy sources.
3639       (CVE-2007-4769, CVE-2007-4772, CVE-2007-6067)
3640      </para>
3641     </listitem>
3642
3643     <listitem>
3644      <para>
3645       Require non-superusers who use <filename>/contrib/dblink</> to use only
3646       password authentication, as a security measure (Joe)
3647      </para>
3648
3649      <para>
3650       The fix that appeared for this in 8.2.5 was incomplete, as it plugged
3651       the hole for only some <filename>dblink</> functions.  (CVE-2007-6601,
3652       CVE-2007-3278)
3653      </para>
3654     </listitem>
3655
3656     <listitem>
3657      <para>
3658       Fix bugs in WAL replay for GIN indexes (Teodor)
3659      </para>
3660     </listitem>
3661
3662     <listitem>
3663      <para>
3664       Fix GIN index build to work properly when
3665       <varname>maintenance_work_mem</> is 4GB or more (Tom)
3666      </para>
3667     </listitem>
3668
3669     <listitem>
3670      <para>
3671       Update time zone data files to <application>tzdata</> release 2007k
3672       (in particular, recent Argentina changes) (Tom)
3673      </para>
3674     </listitem>
3675
3676     <listitem>
3677      <para>
3678       Improve planner's handling of LIKE/regex estimation in non-C locales
3679       (Tom)
3680      </para>
3681     </listitem>
3682
3683     <listitem>
3684      <para>
3685       Fix planning-speed problem for deep outer-join nests, as well as
3686       possible poor choice of join order (Tom)
3687      </para>
3688     </listitem>
3689
3690     <listitem>
3691      <para>
3692       Fix planner failure in some cases of <literal>WHERE false AND var IN
3693       (SELECT ...)</> (Tom)
3694      </para>
3695     </listitem>
3696
3697     <listitem>
3698      <para>
3699       Make <command>CREATE TABLE ... SERIAL</> and
3700       <command>ALTER SEQUENCE ... OWNED BY</> not change the
3701       <function>currval()</> state of the sequence (Tom)
3702      </para>
3703     </listitem>
3704
3705     <listitem>
3706      <para>
3707       Preserve the tablespace and storage parameters of indexes that are
3708       rebuilt by <command>ALTER TABLE ... ALTER COLUMN TYPE</> (Tom)
3709      </para>
3710     </listitem>
3711
3712     <listitem>
3713      <para>
3714       Make archive recovery always start a new WAL timeline, rather than only
3715       when a recovery stop time was used (Simon)
3716      </para>
3717
3718      <para>
3719       This avoids a corner-case risk of trying to overwrite an existing
3720       archived copy of the last WAL segment, and seems simpler and cleaner
3721       than the original definition.
3722      </para>
3723     </listitem>
3724
3725     <listitem>
3726      <para>
3727       Make <command>VACUUM</> not use all of <varname>maintenance_work_mem</>
3728       when the table is too small for it to be useful (Alvaro)
3729      </para>
3730     </listitem>
3731
3732     <listitem>
3733      <para>
3734       Fix potential crash in <function>translate()</> when using a multibyte
3735       database encoding (Tom)
3736      </para>
3737     </listitem>
3738
3739     <listitem>
3740      <para>
3741       Make <function>corr()</> return the correct result for negative
3742       correlation values (Neil)
3743      </para>
3744     </listitem>
3745
3746     <listitem>
3747      <para>
3748       Fix overflow in <literal>extract(epoch from interval)</> for intervals
3749       exceeding 68 years (Tom)
3750      </para>
3751     </listitem>
3752
3753     <listitem>
3754      <para>
3755       Fix PL/Perl to not fail when a UTF-8 regular expression is used
3756       in a trusted function (Andrew)
3757      </para>
3758     </listitem>
3759
3760     <listitem>
3761      <para>
3762       Fix PL/Perl to cope when platform's Perl defines type <literal>bool</>
3763       as <literal>int</> rather than <literal>char</> (Tom)
3764      </para>
3765
3766      <para>
3767       While this could theoretically happen anywhere, no standard build of
3768       Perl did things this way ... until <productname>macOS</> 10.5.
3769      </para>
3770     </listitem>
3771
3772     <listitem>
3773      <para>
3774       Fix PL/Python to work correctly with Python 2.5 on 64-bit machines
3775       (Marko Kreen)
3776      </para>
3777     </listitem>
3778
3779     <listitem>
3780      <para>
3781       Fix PL/Python to not crash on long exception messages (Alvaro)
3782      </para>
3783     </listitem>
3784
3785     <listitem>
3786      <para>
3787       Fix <application>pg_dump</> to correctly handle inheritance child tables
3788       that have default expressions different from their parent's (Tom)
3789      </para>
3790     </listitem>
3791
3792     <listitem>
3793      <para>
3794       Fix <application>libpq</> crash when <varname>PGPASSFILE</> refers
3795       to a file that is not a plain file (Martin Pitt)
3796      </para>
3797     </listitem>
3798
3799     <listitem>
3800      <para>
3801       <application>ecpg</> parser fixes (Michael)
3802      </para>
3803     </listitem>
3804
3805     <listitem>
3806      <para>
3807       Make <filename>contrib/pgcrypto</> defend against
3808       <application>OpenSSL</> libraries that fail on keys longer than 128
3809       bits; which is the case at least on some Solaris versions (Marko Kreen)
3810      </para>
3811     </listitem>
3812
3813     <listitem>
3814      <para>
3815       Make <filename>contrib/tablefunc</>'s <function>crosstab()</> handle
3816       NULL rowid as a category in its own right, rather than crashing (Joe)
3817      </para>
3818     </listitem>
3819
3820     <listitem>
3821      <para>
3822       Fix <type>tsvector</> and <type>tsquery</> output routines to
3823       escape backslashes correctly (Teodor, Bruce)
3824      </para>
3825     </listitem>
3826
3827     <listitem>
3828      <para>
3829       Fix crash of <function>to_tsvector()</> on huge input strings (Teodor)
3830      </para>
3831     </listitem>
3832
3833     <listitem>
3834      <para>
3835       Require a specific version of <productname>Autoconf</> to be used
3836       when re-generating the <command>configure</> script (Peter)
3837      </para>
3838
3839      <para>
3840       This affects developers and packagers only.  The change was made
3841       to prevent accidental use of untested combinations of
3842       <productname>Autoconf</> and <productname>PostgreSQL</> versions.
3843       You can remove the version check if you really want to use a
3844       different <productname>Autoconf</> version, but it's
3845       your responsibility whether the result works or not.
3846      </para>
3847     </listitem>
3848
3849     <listitem>
3850      <para>
3851       Update <function>gettimeofday</> configuration check so that
3852       <productname>PostgreSQL</> can be built on newer versions of
3853       <productname>MinGW</> (Magnus)
3854      </para>
3855     </listitem>
3856
3857    </itemizedlist>
3858
3859   </sect2>
3860  </sect1>
3861
3862  <sect1 id="release-8-2-5">
3863   <title>Release 8.2.5</title>
3864
3865   <formalpara>
3866   <title>Release date:</title>
3867   <para>2007-09-17</para>
3868   </formalpara>
3869
3870   <para>
3871    This release contains a variety of fixes from 8.2.4.
3872    For information about new features in the 8.2 major release, see
3873    <xref linkend="release-8-2">.
3874   </para>
3875
3876   <sect2>
3877    <title>Migration to Version 8.2.5</title>
3878
3879    <para>
3880     A dump/restore is not required for those running 8.2.X.
3881    </para>
3882
3883   </sect2>
3884
3885   <sect2>
3886    <title>Changes</title>
3887
3888    <itemizedlist>
3889
3890     <listitem>
3891      <para>
3892       Prevent index corruption when a transaction inserts rows and
3893       then aborts close to the end of a concurrent <command>VACUUM</>
3894       on the same table (Tom)
3895      </para>
3896     </listitem>
3897
3898     <listitem>
3899      <para>
3900       Fix <literal>ALTER DOMAIN ADD CONSTRAINT</> for cases involving
3901       domains over domains (Tom)
3902      </para>
3903     </listitem>
3904
3905     <listitem>
3906      <para>
3907       Make <command>CREATE DOMAIN ... DEFAULT NULL</> work properly (Tom)
3908      </para>
3909     </listitem>
3910
3911     <listitem>
3912      <para>
3913       Fix some planner problems with outer joins, notably poor
3914       size estimation for <literal>t1 LEFT JOIN t2 WHERE t2.col IS NULL</>
3915       (Tom)
3916      </para>
3917     </listitem>
3918
3919     <listitem>
3920      <para>
3921       Allow the <type>interval</> data type to accept input consisting only of
3922       milliseconds or microseconds (Neil)
3923      </para>
3924     </listitem>
3925
3926     <listitem>
3927      <para>
3928       Allow timezone name to appear before the year in <type>timestamp</> input (Tom)
3929      </para>
3930     </listitem>
3931
3932     <listitem>
3933      <para>
3934       Fixes for <acronym>GIN</> indexes used by <filename>/contrib/tsearch2</> (Teodor)
3935      </para>
3936     </listitem>
3937
3938     <listitem>
3939      <para>
3940       Speed up rtree index insertion (Teodor)
3941      </para>
3942     </listitem>
3943
3944     <listitem>
3945      <para>
3946       Fix excessive logging of <acronym>SSL</> error messages (Tom)
3947      </para>
3948     </listitem>
3949
3950     <listitem>
3951      <para>
3952       Fix logging so that log messages are never interleaved when using
3953       the syslogger process (Andrew)
3954      </para>
3955     </listitem>
3956
3957     <listitem>
3958      <para>
3959       Fix crash when <varname>log_min_error_statement</> logging runs out
3960       of memory (Tom)
3961      </para>
3962     </listitem>
3963
3964     <listitem>
3965      <para>
3966       Fix incorrect handling of some foreign-key corner cases (Tom)
3967      </para>
3968     </listitem>
3969
3970     <listitem>
3971      <para>
3972       Fix <function>stddev_pop(numeric)</> and <function>var_pop(numeric)</> (Tom)
3973      </para>
3974     </listitem>
3975
3976     <listitem>
3977      <para>
3978       Prevent <command>REINDEX</> and <command>CLUSTER</> from failing
3979       due to attempting to process temporary tables of other sessions (Alvaro)
3980      </para>
3981     </listitem>
3982
3983     <listitem>
3984      <para>
3985       Update the time zone database rules, particularly New Zealand's upcoming changes (Tom)
3986      </para>
3987     </listitem>
3988
3989     <listitem>
3990      <para>
3991       Windows socket and semaphore improvements (Magnus)
3992      </para>
3993     </listitem>
3994
3995     <listitem>
3996      <para>
3997       Make <command>pg_ctl -w</> work properly in Windows service mode (Dave Page)
3998      </para>
3999     </listitem>
4000
4001     <listitem>
4002      <para>
4003       Fix memory allocation bug when using <application>MIT Kerberos</> on Windows (Magnus)
4004      </para>
4005     </listitem>
4006
4007     <listitem>
4008      <para>
4009       Suppress timezone name (<literal>%Z</>) in log timestamps on Windows
4010       because of possible encoding mismatches (Tom)
4011      </para>
4012     </listitem>
4013
4014     <listitem>
4015      <para>
4016       Require non-superusers who use <filename>/contrib/dblink</> to use only
4017       password authentication, as a security measure (Joe)
4018      </para>
4019     </listitem>
4020
4021     <listitem>
4022      <para>
4023       Restrict <filename>/contrib/pgstattuple</> functions to superusers, for security reasons (Tom)
4024      </para>
4025     </listitem>
4026
4027     <listitem>
4028      <para>
4029       Do not let <filename>/contrib/intarray</> try to make its GIN opclass
4030       the default (this caused problems at dump/restore) (Tom)
4031      </para>
4032     </listitem>
4033
4034    </itemizedlist>
4035
4036   </sect2>
4037  </sect1>
4038
4039  <sect1 id="release-8-2-4">
4040   <title>Release 8.2.4</title>
4041
4042   <formalpara>
4043   <title>Release date:</title>
4044   <para>2007-04-23</para>
4045   </formalpara>
4046
4047   <para>
4048    This release contains a variety of fixes from 8.2.3,
4049    including a security fix.
4050    For information about new features in the 8.2 major release, see
4051    <xref linkend="release-8-2">.
4052   </para>
4053
4054   <sect2>
4055    <title>Migration to Version 8.2.4</title>
4056
4057    <para>
4058     A dump/restore is not required for those running 8.2.X.
4059    </para>
4060
4061   </sect2>
4062
4063   <sect2>
4064    <title>Changes</title>
4065
4066    <itemizedlist>
4067
4068     <listitem>
4069      <para>
4070       Support explicit placement of the temporary-table schema within
4071       <varname>search_path</>, and disable searching it for functions
4072       and operators (Tom)
4073      </para>
4074
4075      <para>
4076       This is needed to allow a security-definer function to set a
4077       truly secure value of <varname>search_path</>.  Without it,
4078       an unprivileged SQL user can use temporary objects to execute code
4079       with the privileges of the security-definer function (CVE-2007-2138).
4080       See <command>CREATE FUNCTION</> for more information.
4081      </para>
4082     </listitem>
4083
4084     <listitem>
4085      <para>
4086       Fix <varname>shared_preload_libraries</> for Windows
4087       by forcing reload in each backend (Korry Douglas)
4088      </para>
4089     </listitem>
4090
4091     <listitem>
4092      <para>
4093       Fix <function>to_char()</> so it properly upper/lower cases localized day or month
4094       names (Pavel Stehule)
4095      </para>
4096     </listitem>
4097
4098     <listitem>
4099      <para>
4100       <filename>/contrib/tsearch2</> crash fixes (Teodor)
4101      </para>
4102     </listitem>
4103
4104     <listitem>
4105      <para>
4106       Require <command>COMMIT PREPARED</> to be executed in the same
4107       database as the transaction was prepared in (Heikki)
4108      </para>
4109     </listitem>
4110
4111     <listitem>
4112      <para>
4113       Allow <command>pg_dump</> to do binary backups larger than two gigabytes
4114       on Windows (Magnus)
4115      </para>
4116     </listitem>
4117
4118     <listitem>
4119      <para>
4120       New traditional (Taiwan) Chinese <acronym>FAQ</> (Zhou Daojing)
4121      </para>
4122     </listitem>
4123
4124     <listitem>
4125      <para>
4126       Prevent the statistics collector from writing to disk too frequently (Tom)
4127      </para>
4128     </listitem>
4129
4130     <listitem>
4131      <para>
4132       Fix potential-data-corruption bug in how <command>VACUUM FULL</> handles
4133       <command>UPDATE</> chains (Tom, Pavan Deolasee)
4134      </para>
4135     </listitem>
4136
4137     <listitem>
4138      <para>
4139       Fix bug in domains that use array types (Tom)
4140      </para>
4141     </listitem>
4142
4143     <listitem>
4144      <para>
4145       Fix <command>pg_dump</> so it can dump a serial column's sequence
4146       using <option>-t</> when not also dumping the owning table
4147       (Tom)
4148      </para>
4149     </listitem>
4150
4151     <listitem>
4152      <para>
4153       Planner fixes, including improving outer join and bitmap scan
4154       selection logic (Tom)
4155      </para>
4156     </listitem>
4157
4158     <listitem>
4159      <para>
4160       Fix possible wrong answers or crash when a PL/pgSQL function tries
4161       to <literal>RETURN</> from within an <literal>EXCEPTION</> block
4162       (Tom)
4163      </para>
4164     </listitem>
4165
4166     <listitem>
4167      <para>
4168       Fix PANIC during enlargement of a hash index (Tom)
4169      </para>
4170     </listitem>
4171
4172     <listitem>
4173      <para>
4174       Fix POSIX-style timezone specs to follow new USA DST rules (Tom)
4175      </para>
4176     </listitem>
4177
4178    </itemizedlist>
4179
4180   </sect2>
4181  </sect1>
4182
4183  <sect1 id="release-8-2-3">
4184   <title>Release 8.2.3</title>
4185
4186   <formalpara>
4187   <title>Release date:</title>
4188   <para>2007-02-07</para>
4189   </formalpara>
4190
4191   <para>
4192    This release contains two fixes from 8.2.2.
4193    For information about new features in the 8.2 major release, see
4194    <xref linkend="release-8-2">.
4195   </para>
4196
4197   <sect2>
4198    <title>Migration to Version 8.2.3</title>
4199
4200    <para>
4201     A dump/restore is not required for those running 8.2.X.
4202    </para>
4203
4204   </sect2>
4205
4206   <sect2>
4207    <title>Changes</title>
4208
4209    <itemizedlist>
4210
4211     <listitem>
4212      <para>
4213       Remove overly-restrictive check for type length in constraints and
4214       functional indexes(Tom)
4215      </para>
4216     </listitem>
4217
4218     <listitem>
4219      <para>
4220       Fix optimization so MIN/MAX in subqueries can again use indexes (Tom)
4221      </para>
4222     </listitem>
4223
4224    </itemizedlist>
4225
4226   </sect2>
4227  </sect1>
4228
4229  <sect1 id="release-8-2-2">
4230   <title>Release 8.2.2</title>
4231
4232   <formalpara>
4233   <title>Release date:</title>
4234   <para>2007-02-05</para>
4235   </formalpara>
4236
4237   <para>
4238    This release contains a variety of fixes from 8.2.1, including
4239    a security fix.
4240    For information about new features in the 8.2 major release, see
4241    <xref linkend="release-8-2">.
4242   </para>
4243
4244   <sect2>
4245    <title>Migration to Version 8.2.2</title>
4246
4247    <para>
4248     A dump/restore is not required for those running 8.2.X.
4249    </para>
4250
4251   </sect2>
4252
4253   <sect2>
4254    <title>Changes</title>
4255
4256    <itemizedlist>
4257
4258     <listitem>
4259      <para>
4260       Remove security vulnerabilities that allowed connected users
4261       to read backend memory (Tom)
4262      </para>
4263
4264      <para>
4265       The vulnerabilities involve suppressing the normal check that a SQL
4266       function returns the data type it's declared to, and changing the
4267       data type of a table column (CVE-2007-0555, CVE-2007-0556).  These
4268       errors can easily be exploited to cause a backend crash, and in
4269       principle might be used to read database content that the user
4270       should not be able to access.
4271      </para>
4272     </listitem>
4273
4274     <listitem>
4275      <para>
4276       Fix not-so-rare-anymore bug wherein btree index page splits could fail
4277       due to choosing an infeasible split point (Heikki Linnakangas)
4278      </para>
4279     </listitem>
4280
4281     <listitem>
4282      <para>
4283       Fix Borland C compile scripts (L Bayuk)
4284      </para>
4285     </listitem>
4286
4287     <listitem>
4288      <para>
4289       Properly handle <function>to_char('CC')</> for years ending in
4290       <literal>00</> (Tom)
4291      </para>
4292
4293      <para>
4294       Year 2000 is in the twentieth century, not the twenty-first.
4295      </para>
4296     </listitem>
4297
4298     <listitem>
4299      <para>
4300       <filename>/contrib/tsearch2</> localization improvements (Tatsuo, Teodor)
4301      </para>
4302     </listitem>
4303
4304     <listitem>
4305      <para>
4306       Fix incorrect permission check in
4307       <literal>information_schema.key_column_usage</> view (Tom)
4308      </para>
4309
4310      <para>
4311       The symptom is <quote>relation with OID nnnnn does not exist</> errors.
4312       To get this fix without using <command>initdb</>, use <command>CREATE OR
4313       REPLACE VIEW</> to install the corrected definition found in
4314       <filename>share/information_schema.sql</>.  Note you will need to do
4315       this in each database.
4316      </para>
4317     </listitem>
4318
4319     <listitem>
4320      <para>
4321       Improve <command>VACUUM</> performance for databases with many tables (Tom)
4322      </para>
4323     </listitem>
4324
4325     <listitem>
4326      <para>
4327       Fix for rare Assert() crash triggered by <literal>UNION</> (Tom)
4328      </para>
4329     </listitem>
4330
4331     <listitem>
4332      <para>
4333       Fix potentially incorrect results from index searches using
4334       <literal>ROW</> inequality conditions (Tom)
4335      </para>
4336     </listitem>
4337
4338     <listitem>
4339      <para>
4340       Tighten security of multi-byte character processing for UTF8 sequences
4341       over three bytes long (Tom)
4342      </para>
4343     </listitem>
4344
4345     <listitem>
4346      <para>
4347       Fix bogus <quote>permission denied</> failures occurring on Windows
4348       due to attempts to fsync already-deleted files (Magnus, Tom)
4349      </para>
4350     </listitem>
4351
4352     <listitem>
4353      <para>
4354       Fix bug that could cause the statistics collector
4355       to hang on Windows (Magnus)
4356      </para>
4357
4358      <para>
4359       This would in turn lead to autovacuum not working.
4360      </para>
4361     </listitem>
4362
4363     <listitem>
4364      <para>
4365       Fix possible crashes when an already-in-use PL/pgSQL function is
4366       updated (Tom)
4367      </para>
4368     </listitem>
4369
4370     <listitem>
4371      <para>
4372       Improve PL/pgSQL handling of domain types (Sergiy Vyshnevetskiy, Tom)
4373      </para>
4374     </listitem>
4375
4376     <listitem>
4377      <para>
4378       Fix possible errors in processing PL/pgSQL exception blocks (Tom)
4379      </para>
4380     </listitem>
4381
4382    </itemizedlist>
4383
4384   </sect2>
4385  </sect1>
4386
4387  <sect1 id="release-8-2-1">
4388   <title>Release 8.2.1</title>
4389
4390   <formalpara>
4391   <title>Release date:</title>
4392   <para>2007-01-08</para>
4393   </formalpara>
4394
4395   <para>
4396    This release contains a variety of fixes from 8.2.
4397    For information about new features in the 8.2 major release, see
4398    <xref linkend="release-8-2">.
4399   </para>
4400
4401   <sect2>
4402    <title>Migration to Version 8.2.1</title>
4403
4404    <para>
4405     A dump/restore is not required for those running 8.2.
4406    </para>
4407
4408   </sect2>
4409
4410   <sect2>
4411    <title>Changes</title>
4412
4413    <itemizedlist>
4414
4415     <listitem>
4416      <para>
4417       Fix crash with <literal>SELECT</> ... <literal>LIMIT ALL</> (also
4418       <literal>LIMIT NULL</>) (Tom)
4419      </para>
4420     </listitem>
4421
4422     <listitem>
4423      <para>
4424       <filename>Several /contrib/tsearch2</> fixes (Teodor)
4425      </para>
4426     </listitem>
4427
4428     <listitem>
4429      <para>
4430       On Windows, make log messages coming from the operating system use
4431       <acronym>ASCII</> encoding (Hiroshi Saito)
4432      </para>
4433
4434      <para>
4435       This fixes a conversion problem when there is a mismatch between
4436       the encoding of the operating system and database server.
4437      </para>
4438     </listitem>
4439
4440     <listitem>
4441      <para>
4442       Fix Windows linking of <application>pg_dump</> using
4443       <filename>win32.mak</>
4444       (Hiroshi Saito)
4445      </para>
4446     </listitem>
4447
4448     <listitem>
4449      <para>
4450       Fix planner mistakes for outer join queries (Tom)
4451      </para>
4452     </listitem>
4453
4454     <listitem>
4455      <para>
4456       Fix several problems in queries involving sub-SELECTs (Tom)
4457      </para>
4458     </listitem>
4459
4460     <listitem>
4461      <para>
4462       Fix potential crash in SPI during subtransaction abort (Tom)
4463      </para>
4464
4465      <para>
4466       This affects all PL functions since they all use SPI.
4467      </para>
4468     </listitem>
4469
4470     <listitem>
4471      <para>
4472       Improve build speed of <acronym>PDF</> documentation (Peter)
4473      </para>
4474     </listitem>
4475
4476     <listitem>
4477      <para>
4478       Re-add <acronym>JST</> (Japan) timezone abbreviation (Tom)
4479      </para>
4480     </listitem>
4481
4482     <listitem>
4483      <para>
4484       Improve optimization decisions related to index scans (Tom)
4485      </para>
4486     </listitem>
4487
4488     <listitem>
4489      <para>
4490       Have <application>psql</> print multi-byte combining characters as
4491       before, rather than output as <literal>\u</> (Tom)
4492      </para>
4493     </listitem>
4494
4495     <listitem>
4496      <para>
4497       Improve index usage of regular expressions that use parentheses (Tom)
4498      </para>
4499
4500      <para>
4501       This improves <application>psql</> <literal>\d</> performance also.
4502      </para>
4503     </listitem>
4504
4505     <listitem>
4506      <para>
4507       Make <application>pg_dumpall</> assume that databases have public
4508       <literal>CONNECT</> privilege, when dumping from a pre-8.2 server (Tom)
4509      </para>
4510
4511      <para>
4512       This preserves the previous behavior that anyone can connect to a
4513       database if allowed by <filename>pg_hba.conf</>.
4514      </para>
4515     </listitem>
4516
4517    </itemizedlist>
4518
4519   </sect2>
4520  </sect1>
4521
4522  <sect1 id="release-8-2">
4523   <title>Release 8.2</title>
4524
4525   <formalpara>
4526    <title>Release date:</title>
4527    <para>2006-12-05</para>
4528   </formalpara>
4529
4530   <sect2>
4531    <title>Overview</title>
4532
4533    <para>
4534     This release adds many functionality and performance improvements that
4535     were requested by users, including:
4536
4537    <itemizedlist>
4538
4539      <listitem>
4540       <para>
4541        Query language enhancements including <command>INSERT/UPDATE/DELETE
4542        RETURNING</command>, multirow <literal>VALUES</literal> lists, and
4543        optional target-table alias in
4544        <command>UPDATE</>/<command>DELETE</command>
4545       </para>
4546      </listitem>
4547
4548      <listitem>
4549       <para>
4550        Index creation without blocking concurrent
4551        <command>INSERT</>/<command>UPDATE</>/<command>DELETE</>
4552        operations
4553       </para>
4554      </listitem>
4555
4556      <listitem>
4557       <para>
4558        Many query optimization improvements, including support for
4559        reordering outer joins
4560       </para>
4561      </listitem>
4562
4563      <listitem>
4564       <para>
4565        Improved sorting performance with lower memory usage
4566       </para>
4567      </listitem>
4568
4569      <listitem>
4570       <para>
4571        More efficient locking with better concurrency
4572       </para>
4573      </listitem>
4574
4575      <listitem>
4576       <para>
4577        More efficient vacuuming
4578       </para>
4579      </listitem>
4580
4581      <listitem>
4582       <para>
4583        Easier administration of warm standby servers
4584       </para>
4585      </listitem>
4586
4587      <listitem>
4588       <para>
4589        New <literal>FILLFACTOR</literal> support for tables and indexes
4590       </para>
4591      </listitem>
4592
4593      <listitem>
4594       <para>
4595        Monitoring, logging, and performance tuning additions
4596       </para>
4597      </listitem>
4598
4599      <listitem>
4600       <para>
4601        More control over creating and dropping objects
4602       </para>
4603      </listitem>
4604
4605      <listitem>
4606       <para>
4607        Table inheritance relationships can be defined
4608        for and removed from pre-existing tables
4609       </para>
4610      </listitem>
4611
4612      <listitem>
4613       <para>
4614        <command>COPY TO</command> can copy the output of an arbitrary
4615        <command>SELECT</command> statement
4616       </para>
4617      </listitem>
4618
4619      <listitem>
4620       <para>
4621        Array improvements, including nulls in arrays
4622       </para>
4623      </listitem>
4624
4625      <listitem>
4626       <para>
4627        Aggregate-function improvements, including multiple-input
4628        aggregates and SQL:2003 statistical functions
4629       </para>
4630      </listitem>
4631
4632      <listitem>
4633       <para>
4634        Many <filename>contrib/</filename> improvements
4635       </para>
4636      </listitem>
4637
4638     </itemizedlist>
4639
4640    </para>
4641
4642   </sect2>
4643
4644   <sect2>
4645    <title>Migration to Version 8.2</title>
4646
4647    <para>
4648     A dump/restore using <application>pg_dump</application> is
4649     required for those wishing to migrate data from any previous
4650     release.
4651    </para>
4652
4653    <para>
4654     Observe the following incompatibilities:
4655    </para>
4656
4657    <itemizedlist>
4658
4659      <listitem>
4660       <para>
4661        Set <link
4662        linkend="guc-escape-string-warning"><varname>escape_string_warning</></link>
4663        to <literal>on</> by default (Bruce)
4664       </para>
4665
4666       <para>
4667        This issues a warning if backslash escapes are used in
4668        <link linkend="sql-syntax-strings">non-escape (non-<literal>E''</>)
4669        strings</link>.
4670       </para>
4671      </listitem>
4672
4673      <listitem>
4674       <para>
4675        Change the <link linkend="sql-syntax-row-constructors">row
4676        constructor syntax</link> (<literal>ROW(...)</>) so that
4677        list elements <literal>foo.*</> will be expanded to a list
4678        of their member fields, rather than creating a nested
4679        row type field as formerly (Tom)
4680       </para>
4681
4682       <para>
4683        The new behavior is substantially more useful since it
4684        allows, for example, triggers to check for data changes
4685        with <literal>IF row(new.*) IS DISTINCT FROM row(old.*)</>.
4686        The old behavior is still available by omitting <literal>.*</>.
4687       </para>
4688      </listitem>
4689
4690      <listitem>
4691       <para>
4692        Make <link linkend="row-wise-comparison">row comparisons</link>
4693        follow <acronym>SQL</> standard semantics and allow them
4694        to be used in index scans (Tom)
4695       </para>
4696
4697       <para>
4698        Previously, row = and &lt;&gt; comparisons followed the
4699        standard but &lt; &lt;= &gt; &gt;= did not.  A row comparison
4700        can now be used as an index constraint for a multicolumn
4701        index matching the row value.
4702       </para>
4703      </listitem>
4704
4705      <listitem>
4706       <para>
4707        Make <link linkend="functions-comparison">row <literal>IS <optional>NOT</> NULL</literal></link>
4708        tests follow <acronym>SQL</> standard semantics (Tom)
4709       </para>
4710
4711       <para>
4712        The former behavior conformed to the standard for simple cases
4713        with <literal>IS NULL</>, but <literal>IS NOT NULL</> would return
4714        true if any row field was non-null, whereas the standard says it
4715        should return true only when all fields are non-null.
4716       </para>
4717      </listitem>
4718
4719      <listitem>
4720       <para>
4721        Make <link linkend="SQL-SET-CONSTRAINTS"><command>SET
4722        CONSTRAINT</></link> affect only one constraint (Kris Jurka)
4723       </para>
4724
4725       <para>
4726        In previous releases, <command>SET CONSTRAINT</> modified
4727        all constraints with a matching name.  In this release,
4728        the schema search path is used to modify only the first
4729        matching constraint.  A schema specification is also
4730        supported.  This more nearly conforms to the SQL standard.
4731       </para>
4732      </listitem>
4733
4734      <listitem>
4735       <para>
4736        Remove <literal>RULE</> permission for tables, for security reasons
4737        (Tom)
4738       </para>
4739
4740       <para>
4741        As of this release, only a table's owner can create or modify
4742        rules for the table.  For backwards compatibility,
4743        <command>GRANT</>/<command>REVOKE RULE</> is still accepted,
4744        but it does nothing.
4745       </para>
4746      </listitem>
4747
4748      <listitem>
4749       <para>
4750        Array comparison improvements (Tom)
4751       </para>
4752
4753       <para>
4754        Now array dimensions are also compared.
4755       </para>
4756      </listitem>
4757
4758      <listitem>
4759       <para>
4760        Change <link linkend="functions-array">array concatenation</link>
4761        to match documented behavior (Tom)
4762       </para>
4763
4764       <para>
4765        This changes the previous behavior where concatenation
4766        would modify the array lower bound.
4767       </para>
4768      </listitem>
4769
4770      <listitem>
4771       <para>
4772        Make command-line options of <application>postmaster</>
4773        and <link linkend="app-postgres"><application>postgres</></link>
4774        identical (Peter)
4775       </para>
4776
4777       <para>
4778        This allows the postmaster to pass arguments to each backend
4779        without using <literal>-o</>.  Note that some options are now
4780        only available as long-form options, because there were conflicting
4781        single-letter options.
4782       </para>
4783      </listitem>
4784
4785      <listitem>
4786       <para>
4787        Deprecate use of <application>postmaster</> symbolic link (Peter)
4788       </para>
4789
4790       <para>
4791        <application>postmaster</> and <application>postgres</>
4792        commands now act identically, with the behavior determined
4793        by command-line options.  The <application>postmaster</> symbolic link is
4794        kept for compatibility, but is not really needed.
4795       </para>
4796      </listitem>
4797
4798      <listitem>
4799       <para>
4800        Change <link
4801        linkend="guc-log-duration"><varname>log_duration</></link>
4802        to output even if the query is not output (Tom)
4803       </para>
4804
4805       <para>
4806        In prior releases, <varname>log_duration</> only printed if
4807        the query appeared earlier in the log.
4808       </para>
4809      </listitem>
4810
4811      <listitem>
4812       <para>
4813        Make <link
4814        linkend="functions-formatting"><function>to_char(time)</></link>
4815        and <link
4816        linkend="functions-formatting"><function>to_char(interval)</></link>
4817        treat <literal>HH</> and <literal>HH12</> as 12-hour
4818        intervals
4819       </para>
4820
4821       <para>
4822        Most applications should use <literal>HH24</> unless they
4823        want a 12-hour display.
4824       </para>
4825      </listitem>
4826
4827      <listitem>
4828       <para>
4829        Zero unmasked bits in conversion from <link
4830        linkend="datatype-inet"><type>INET</></link> to <link
4831        linkend="datatype-inet"><type>CIDR</></link> (Tom)
4832       </para>
4833
4834       <para>
4835        This ensures that the converted value is actually valid for
4836        <type>CIDR</>.
4837       </para>
4838      </listitem>
4839
4840      <listitem>
4841       <para>
4842        Remove <varname>australian_timezones</> configuration variable
4843        (Joachim Wieland)
4844       </para>
4845
4846       <para>
4847        This variable has been superseded by a more general facility
4848        for configuring timezone abbreviations.
4849       </para>
4850      </listitem>
4851
4852      <listitem>
4853       <para>
4854        Improve cost estimation for nested-loop index scans (Tom)
4855       </para>
4856
4857       <para>
4858        This might eliminate the need to set unrealistically small
4859        values of <link
4860        linkend="guc-random-page-cost"><varname>random_page_cost</></link>.
4861        If you have been using a very small <varname>random_page_cost</>,
4862        please recheck your test cases.
4863       </para>
4864      </listitem>
4865
4866      <listitem>
4867       <para>
4868        Change behavior of <command>pg_dump</> <literal>-n</> and
4869        <literal>-t</> options.  (Greg Sabino Mullane)
4870       </para>
4871       <para>
4872        See the <command>pg_dump</> manual page for details.
4873       </para>
4874      </listitem>
4875
4876      <listitem>
4877       <para>
4878        Change <link linkend="libpq"><application>libpq</></link>
4879        <function>PQdsplen()</> to return a useful value (Martijn
4880        van Oosterhout)
4881       </para>
4882      </listitem>
4883
4884      <listitem>
4885       <para>
4886        Declare <link linkend="libpq"><application>libpq</></link>
4887        <function>PQgetssl()</> as returning <literal>void *</>,
4888        rather than <literal>SSL *</> (Martijn van Oosterhout)
4889       </para>
4890
4891       <para>
4892        This allows applications to use the function without including
4893        the OpenSSL headers.
4894       </para>
4895      </listitem>
4896
4897      <listitem>
4898       <para>
4899        C-language loadable modules must now include a
4900        <link linkend="xfunc-c-dynload"><literal>PG_MODULE_MAGIC</></link>
4901        macro call for version compatibility checking
4902        (Martijn van Oosterhout)
4903       </para>
4904      </listitem>
4905
4906      <listitem>
4907       <para>
4908        For security's sake, modules used by a PL/PerlU function are no
4909        longer available to PL/Perl functions (Andrew)
4910       </para>
4911       <note>
4912        <para>
4913         This also implies that data can no longer be shared between a PL/Perl
4914         function and a PL/PerlU function.
4915         Some Perl installations have not been compiled with the correct flags
4916         to allow multiple interpreters to exist within a single process.
4917         In this situation PL/Perl and PL/PerlU cannot both be used in a
4918         single backend. The solution is to get a Perl installation which
4919         supports multiple interpreters.
4920        </para>
4921       </note>
4922      </listitem>
4923
4924      <listitem>
4925       <para>
4926        In <filename>contrib/xml2/</>, rename <function>xml_valid()</> to
4927        <function>xml_is_well_formed()</> (Tom)
4928       </para>
4929
4930       <para>
4931        <function>xml_valid()</> will remain for backward compatibility,
4932        but its behavior will change to do schema checking in a future
4933        release.
4934       </para>
4935      </listitem>
4936
4937      <listitem>
4938       <para>
4939        Remove <filename>contrib/ora2pg/</>, now at <ulink
4940        url="http://www.samse.fr/GPL/ora2pg"></ulink>
4941       </para>
4942      </listitem>
4943
4944      <listitem>
4945       <para>
4946        Remove contrib modules that have been migrated to PgFoundry:
4947        <filename>adddepend</>, <filename>dbase</>, <filename>dbmirror</>,
4948        <filename>fulltextindex</>, <filename>mac</>, <filename>userlock</>
4949       </para>
4950      </listitem>
4951
4952      <listitem>
4953       <para>
4954        Remove abandoned contrib modules:
4955        <filename>mSQL-interface</>, <filename>tips</>
4956       </para>
4957      </listitem>
4958
4959      <listitem>
4960       <para>
4961        Remove <acronym>QNX</> and <acronym>BEOS</> ports (Bruce)
4962       </para>
4963
4964       <para>
4965        These ports no longer had active maintainers.
4966       </para>
4967      </listitem>
4968
4969    </itemizedlist>
4970   </sect2>
4971
4972   <sect2>
4973    <title>Changes</title>
4974
4975    <para>
4976     Below you will find a detailed account of the
4977     changes between <productname>PostgreSQL</productname> 8.2 and
4978     the previous major release.
4979    </para>
4980
4981    <sect3>
4982     <title>Performance Improvements</title>
4983     <itemizedlist>
4984
4985      <listitem>
4986       <para>
4987        Allow the planner to reorder <link linkend="queries-join">outer
4988        joins</link> in some circumstances (Tom)
4989       </para>
4990
4991       <para>
4992        In previous releases, outer joins would always be evaluated in
4993        the order written in the query. This change allows the
4994        query optimizer to consider reordering outer joins, in cases where
4995        it can determine that the join order can be changed without
4996        altering the meaning of the query.  This can make a
4997        considerable performance difference for queries involving
4998        multiple outer joins or mixed inner and outer joins.
4999       </para>
5000      </listitem>
5001
5002      <listitem>
5003       <para>
5004        Improve efficiency of <link
5005        linkend="functions-comparisons"><literal>IN</>
5006        (list-of-expressions)</link> clauses (Tom)
5007       </para>
5008      </listitem>
5009
5010      <listitem>
5011       <para>
5012        Improve sorting speed and reduce memory usage (Simon, Tom)
5013       </para>
5014      </listitem>
5015
5016      <listitem>
5017       <para>
5018        Improve subtransaction performance (Alvaro, Itagaki Takahiro,
5019        Tom)
5020       </para>
5021      </listitem>
5022
5023      <listitem>
5024       <para>
5025        Add <literal>FILLFACTOR</> to <link
5026        linkend="SQL-CREATETABLE">table</link> and <link
5027        linkend="SQL-CREATEINDEX">index</link> creation (ITAGAKI
5028        Takahiro)
5029       </para>
5030
5031       <para>
5032        This leaves extra free space in each table or index page,
5033        allowing improved performance as the database grows.  This
5034        is particularly valuable to maintain clustering.
5035       </para>
5036      </listitem>
5037
5038      <listitem>
5039       <para>
5040        Increase default values for <link
5041        linkend="guc-shared-buffers"><varname>shared_buffers</></link>
5042        and <varname>max_fsm_pages</>
5043        (Andrew)
5044       </para>
5045      </listitem>
5046
5047      <listitem>
5048       <para>
5049        Improve locking performance by breaking the lock manager tables into
5050        sections
5051        (Tom)
5052       </para>
5053
5054       <para>
5055        This allows locking to be more fine-grained, reducing
5056        contention.
5057       </para>
5058      </listitem>
5059
5060      <listitem>
5061       <para>
5062        Reduce locking requirements of sequential scans (Qingqing
5063        Zhou)
5064       </para>
5065      </listitem>
5066
5067      <listitem>
5068       <para>
5069        Reduce locking required for database creation and destruction
5070        (Tom)
5071       </para>
5072      </listitem>
5073
5074      <listitem>
5075       <para>
5076        Improve the optimizer's selectivity estimates for <link
5077        linkend="functions-like"><literal>LIKE</></link>, <link
5078        linkend="functions-like"><literal>ILIKE</></link>, and
5079        <link linkend="functions-posix-regexp">regular expression</link>
5080        operations (Tom)
5081       </para>
5082      </listitem>
5083
5084      <listitem>
5085       <para>
5086        Improve planning of joins to <link linkend="ddl-inherit">inherited
5087        tables</link> and <link linkend="queries-union"><literal>UNION
5088        ALL</></link> views (Tom)
5089       </para>
5090      </listitem>
5091
5092      <listitem>
5093       <para>
5094        Allow <link linkend="guc-constraint-exclusion">constraint
5095        exclusion</link> to be applied to <link
5096        linkend="ddl-inherit">inherited</link> <command>UPDATE</> and
5097        <command>DELETE</> queries (Tom)
5098       </para>
5099
5100       <para>
5101        <command>SELECT</> already honored constraint exclusion.
5102       </para>
5103      </listitem>
5104
5105      <listitem>
5106       <para>
5107        Improve planning of constant <literal>WHERE</> clauses, such as
5108        a condition that depends only on variables inherited from an
5109        outer query level (Tom)
5110       </para>
5111      </listitem>
5112
5113      <listitem>
5114       <para>
5115        Protocol-level unnamed prepared statements are re-planned
5116        for each set of <literal>BIND</> values (Tom)
5117       </para>
5118
5119       <para>
5120        This improves performance because the exact parameter values
5121        can be used in the plan.
5122       </para>
5123      </listitem>
5124
5125      <listitem>
5126       <para>
5127        Speed up vacuuming of B-Tree indexes (Heikki Linnakangas,
5128        Tom)
5129       </para>
5130      </listitem>
5131
5132      <listitem>
5133       <para>
5134        Avoid extra scan of tables without indexes during <link
5135        linkend="SQL-VACUUM"><command>VACUUM</></link> (Greg Stark)
5136       </para>
5137      </listitem>
5138
5139      <listitem>
5140       <para>
5141        Improve multicolumn <link linkend="GiST"><acronym>GiST</></link>
5142        indexing (Oleg, Teodor)
5143       </para>
5144      </listitem>
5145
5146      <listitem>
5147       <para>
5148        Remove dead index entries before B-Tree page split (Junji
5149        Teramoto)
5150       </para>
5151      </listitem>
5152
5153     </itemizedlist>
5154
5155    </sect3>
5156
5157    <sect3>
5158     <title>Server Changes</title>
5159     <itemizedlist>
5160
5161      <listitem>
5162       <para>
5163        Allow a forced switch to a new transaction log file (Simon, Tom)
5164       </para>
5165
5166       <para>
5167        This is valuable for keeping warm standby slave servers
5168        in sync with the master.  Transaction log file switching now also happens
5169        automatically during <link
5170        linkend="functions-admin"><function>pg_stop_backup()</></link>.
5171        This ensures that all
5172        transaction log files needed for recovery can be archived immediately.
5173       </para>
5174      </listitem>
5175
5176      <listitem>
5177       <para>
5178        Add <acronym>WAL</> informational functions (Simon)
5179       </para>
5180
5181       <para>
5182        Add functions for interrogating the current transaction log insertion
5183        point and determining <acronym>WAL</> filenames from the
5184        hex <acronym>WAL</> locations displayed by <link
5185        linkend="functions-admin"><function>pg_stop_backup()</></link>
5186        and related functions.
5187       </para>
5188      </listitem>
5189
5190      <listitem>
5191       <para>
5192        Improve recovery from a crash during <acronym>WAL</> replay (Simon)
5193       </para>
5194
5195       <para>
5196        The server now does periodic checkpoints during <acronym>WAL</>
5197        recovery, so if there is a crash, future <acronym>WAL</>
5198        recovery is shortened.  This also eliminates the need for
5199        warm standby servers to replay the entire log since the
5200        base backup if they crash.
5201       </para>
5202      </listitem>
5203
5204      <listitem>
5205       <para>
5206        Improve reliability of long-term <acronym>WAL</> replay
5207        (Heikki, Simon, Tom)
5208       </para>
5209
5210       <para>
5211        Formerly, trying to roll forward through more than 2 billion
5212        transactions would not work due to XID wraparound.  This meant
5213        warm standby servers had to be reloaded
5214        from fresh base backups periodically.
5215       </para>
5216      </listitem>
5217
5218      <listitem>
5219       <para>
5220        Add <link
5221        linkend="guc-archive-timeout"><varname>archive_timeout</></link>
5222        to force transaction log file switches at a given interval (Simon)
5223       </para>
5224
5225       <para>
5226        This enforces a maximum replication delay for warm standby servers.
5227       </para>
5228      </listitem>
5229
5230      <listitem>
5231       <para>
5232        Add native <link linkend="auth-ldap"><acronym>LDAP</></link>
5233        authentication (Magnus Hagander)
5234       </para>
5235
5236       <para>
5237        This is particularly useful for platforms that do not
5238        support <acronym>PAM</>, such as Windows.
5239       </para>
5240      </listitem>
5241
5242      <listitem>
5243       <para>
5244        Add <link linkend="sql-grant-description-objects"><literal>GRANT
5245        CONNECT ON DATABASE</></link> (Gevik Babakhani)
5246       </para>
5247
5248       <para>
5249        This gives SQL-level control over database access.  It works as
5250        an additional filter on top of the existing
5251        <link linkend="auth-pg-hba-conf"><filename>pg_hba.conf</></link>
5252        controls.
5253       </para>
5254      </listitem>
5255
5256      <listitem>
5257       <para>
5258        Add support for <link linkend="ssl-tcp"><acronym>SSL</>
5259        Certificate Revocation List</link> (<acronym>CRL</>) files
5260        (Libor Hoho&scaron;)
5261       </para>
5262
5263       <para>
5264        The server and <application>libpq</> both recognize <acronym>CRL</>
5265        files now.
5266       </para>
5267      </listitem>
5268
5269      <listitem>
5270       <para>
5271        <link linkend="GiST"><acronym>GiST</></link> indexes are
5272        now clusterable (Teodor)
5273       </para>
5274      </listitem>
5275
5276      <listitem>
5277       <para>
5278        Remove routine autovacuum server log entries (Bruce)
5279       </para>
5280
5281       <para>
5282        <link
5283        linkend="monitoring-stats-views-table"><literal>pg_stat_activity</></link>
5284        now shows autovacuum activity.
5285       </para>
5286      </listitem>
5287
5288      <listitem>
5289       <para>
5290        Track maximum XID age within individual tables, instead of whole databases (Alvaro)
5291       </para>
5292
5293       <para>
5294        This reduces the overhead involved in preventing transaction
5295        ID wraparound, by avoiding unnecessary VACUUMs.
5296       </para>
5297      </listitem>
5298
5299      <listitem>
5300       <para>
5301        Add last vacuum and analyze timestamp columns to the stats
5302        collector (Larry Rosenman)
5303       </para>
5304
5305       <para>
5306        These values now appear in the <link
5307        linkend="monitoring-stats-views-table"><literal>pg_stat_*_tables</></link>
5308        system views.
5309       </para>
5310      </listitem>
5311
5312      <listitem>
5313       <para>
5314        Improve performance of statistics monitoring, especially
5315        <varname>stats_command_string</>
5316        (Tom, Bruce)
5317       </para>
5318
5319       <para>
5320        This release enables <varname>stats_command_string</> by
5321        default, now that its overhead is minimal.  This means
5322        <link
5323        linkend="monitoring-stats-views-table"><literal>pg_stat_activity</></link>
5324        will now show all active queries by default.
5325       </para>
5326      </listitem>
5327
5328      <listitem>
5329       <para>
5330        Add a <literal>waiting</> column to <link
5331        linkend="monitoring-stats-views-table"><literal>pg_stat_activity</></link>
5332        (Tom)
5333       </para>
5334
5335       <para>
5336        This allows <structname>pg_stat_activity</> to show all the
5337        information included in the <application>ps</> display.
5338       </para>
5339      </listitem>
5340
5341      <listitem>
5342       <para>
5343        Add configuration parameter <link
5344        linkend="guc-update-process-title"><varname>update_process_title</></link>
5345        to control whether the <application>ps</> display is updated
5346        for every command (Bruce)
5347       </para>
5348
5349       <para>
5350        On platforms where it is expensive to update the <application>ps</>
5351        display, it might be worthwhile to turn this off and rely solely on
5352        <structname>pg_stat_activity</> for status information.
5353       </para>
5354      </listitem>
5355
5356      <listitem>
5357       <para>
5358        Allow units to be specified in configuration settings
5359        (Peter)
5360       </para>
5361
5362       <para>
5363        For example, you can now set <link
5364        linkend="guc-shared-buffers"><varname>shared_buffers</></link>
5365        to <literal>32MB</> rather than mentally converting sizes.
5366       </para>
5367      </listitem>
5368
5369      <listitem>
5370       <para>
5371        Add support for <link linkend="config-setting">include
5372        directives</link> in <filename>postgresql.conf</> (Joachim
5373        Wieland)
5374       </para>
5375      </listitem>
5376
5377      <listitem>
5378       <para>
5379        Improve logging of protocol-level prepare/bind/execute
5380        messages (Bruce, Tom)
5381       </para>
5382
5383       <para>
5384        Such logging now shows statement names, bind parameter
5385        values, and the text of the query being executed.  Also,
5386        the query text is properly included in logged error messages
5387        when enabled by <varname>log_min_error_statement</>.
5388       </para>
5389      </listitem>
5390
5391      <listitem>
5392       <para>
5393        Prevent <link
5394        linkend="guc-max-stack-depth"><varname>max_stack_depth</></link>
5395        from being set to unsafe values
5396       </para>
5397
5398       <para>
5399        On platforms where we can determine the actual kernel stack depth
5400        limit (which is most), make sure that the initial default value of
5401        <varname>max_stack_depth</> is safe, and reject attempts to set it
5402        to unsafely large values.
5403       </para>
5404      </listitem>
5405
5406      <listitem>
5407       <para>
5408        Enable highlighting of error location in query in more
5409        cases (Tom)
5410       </para>
5411
5412       <para>
5413        The server is now able to report a specific error location for
5414        some semantic errors (such as unrecognized column name), rather
5415        than just for basic syntax errors as before.
5416       </para>
5417      </listitem>
5418
5419      <listitem>
5420       <para>
5421        Fix <quote>failed to re-find parent key</> errors in
5422        <command>VACUUM</> (Tom)
5423       </para>
5424      </listitem>
5425
5426      <listitem>
5427       <para>
5428        Clean out <filename>pg_internal.init</> cache files during server
5429        restart (Simon)
5430       </para>
5431
5432       <para>
5433        This avoids a hazard that the cache files might contain stale
5434        data after PITR recovery.
5435       </para>
5436      </listitem>
5437
5438      <listitem>
5439       <para>
5440        Fix race condition for truncation of a large relation across a
5441        gigabyte boundary by <command>VACUUM</> (Tom)
5442       </para>
5443      </listitem>
5444
5445      <listitem>
5446       <para>
5447        Fix bug causing needless deadlock errors on row-level locks (Tom)
5448       </para>
5449      </listitem>
5450
5451      <listitem>
5452       <para>
5453        Fix bugs affecting multi-gigabyte hash indexes (Tom)
5454       </para>
5455      </listitem>
5456
5457      <listitem>
5458       <para>
5459        Each backend process is now its own process group leader (Tom)
5460       </para>
5461
5462       <para>
5463        This allows query cancel to abort subprocesses invoked from a
5464        backend or archive/recovery process.
5465       </para>
5466      </listitem>
5467
5468     </itemizedlist>
5469
5470    </sect3>
5471
5472    <sect3>
5473     <title>Query Changes</title>
5474     <itemizedlist>
5475
5476      <listitem>
5477       <para>
5478        Add <link linkend="SQL-INSERT"><command>INSERT</></link>/<link
5479        linkend="SQL-UPDATE"><command>UPDATE</></link>/<link
5480        linkend="SQL-DELETE"><command>DELETE</></link>
5481        <literal>RETURNING</> (Jonah Harris, Tom)
5482       </para>
5483
5484       <para>
5485        This allows these commands to return values, such as the
5486        computed serial key for a new row.  In the <command>UPDATE</>
5487        case, values from the updated version of the row are returned.
5488       </para>
5489      </listitem>
5490
5491      <listitem>
5492       <para>
5493        Add support for multiple-row <link
5494        linkend="queries-values"><literal>VALUES</></link> clauses,
5495        per SQL standard (Joe, Tom)
5496       </para>
5497
5498       <para>
5499        This allows <command>INSERT</> to insert multiple rows of
5500        constants, or queries to generate result sets using constants.
5501        For example, <literal>INSERT ...  VALUES (...), (...),
5502        ....</>, and <literal>SELECT * FROM (VALUES (...), (...),
5503        ....) AS alias(f1, ...)</>.
5504       </para>
5505      </listitem>
5506
5507      <listitem>
5508       <para>
5509        Allow <link linkend="SQL-UPDATE"><command>UPDATE</></link>
5510        and <link linkend="SQL-DELETE"><command>DELETE</></link>
5511        to use an alias for the target table (Atsushi Ogawa)
5512       </para>
5513
5514       <para>
5515        The SQL standard does not permit an alias in these commands, but
5516        many database systems allow one anyway for notational convenience.
5517       </para>
5518      </listitem>
5519
5520      <listitem>
5521       <para>
5522        Allow <link linkend="SQL-UPDATE"><command>UPDATE</></link>
5523        to set multiple columns with a list of values (Susanne
5524        Ebrecht)
5525       </para>
5526
5527       <para>
5528        This is basically a short-hand for assigning the columns
5529        and values in pairs.  The syntax is <literal>UPDATE tab
5530        SET (<replaceable>column</>, ...) = (<replaceable>val</>, ...)</>.
5531       </para>
5532      </listitem>
5533
5534      <listitem>
5535       <para>
5536        Make row comparisons work per standard (Tom)
5537       </para>
5538
5539       <para>
5540        The forms &lt;, &lt;=, &gt;, &gt;= now compare rows lexicographically,
5541        that is, compare the first elements, if equal compare the second
5542        elements, and so on.  Formerly they expanded to an AND condition
5543        across all the elements, which was neither standard nor very useful.
5544       </para>
5545      </listitem>
5546
5547      <listitem>
5548       <para>
5549        Add <link linkend="SQL-TRUNCATE"><literal>CASCADE</></link>
5550        option to <command>TRUNCATE</> (Joachim Wieland)
5551       </para>
5552
5553       <para>
5554        This causes <command>TRUNCATE</> to automatically include all tables
5555        that reference the specified table(s) via foreign keys.  While
5556        convenient, this is a dangerous tool &mdash; use with caution!
5557       </para>
5558      </listitem>
5559
5560      <listitem>
5561       <para>
5562        Support <literal>FOR UPDATE</> and <literal>FOR SHARE</>
5563        in the same <link linkend="SQL-INSERT"><literal>SELECT</></link>
5564        command (Tom)
5565       </para>
5566      </listitem>
5567
5568      <listitem>
5569       <para>
5570        Add <link linkend="functions-comparisons"><literal>IS NOT
5571        DISTINCT FROM</></link> (Pavel Stehule)
5572       </para>
5573
5574       <para>
5575        This operator is similar to equality (<literal>=</>), but
5576        evaluates to true when both left and right operands are
5577        <literal>NULL</>, and to false when just one is, rather than
5578        yielding <literal>NULL</> in these cases.
5579       </para>
5580      </listitem>
5581
5582      <listitem>
5583       <para>
5584        Improve the length output used by <link
5585        linkend="queries-union"><literal>UNION</></link>/<literal>INTERSECT</>/<literal>EXCEPT</>
5586        (Tom)
5587       </para>
5588
5589       <para>
5590        When all corresponding columns are of the same defined length, that
5591        length is used for the result, rather than a generic length.
5592       </para>
5593      </listitem>
5594
5595      <listitem>
5596       <para>
5597        Allow <link linkend="functions-like"><literal>ILIKE</></link>
5598        to work for multi-byte encodings (Tom)
5599       </para>
5600
5601       <para>
5602        Internally, <literal>ILIKE</> now calls <function>lower()</>
5603        and then uses <literal>LIKE</>.  Locale-specific regular
5604        expression patterns still do not work in these encodings.
5605       </para>
5606      </listitem>
5607
5608      <listitem>
5609       <para>
5610        Enable <link
5611        linkend="guc-standard-conforming-strings"><varname>standard_conforming_strings</></link>
5612        to be turned <literal>on</> (Kevin Grittner)
5613       </para>
5614
5615       <para>
5616        This allows backslash escaping in strings to be disabled,
5617        making <productname>PostgreSQL</> more
5618        standards-compliant.  The default is <literal>off</> for backwards
5619        compatibility, but future releases will default this to <literal>on</>.
5620       </para>
5621      </listitem>
5622
5623      <listitem>
5624       <para>
5625        Do not flatten subqueries that contain <literal>volatile</>
5626        functions in their target lists (Jaime Casanova)
5627       </para>
5628
5629       <para>
5630        This prevents surprising behavior due to multiple evaluation
5631        of a <literal>volatile</> function (such as <function>random()</>
5632        or <function>nextval()</>).  It might cause performance
5633        degradation in the presence of functions that are unnecessarily
5634        marked as <literal>volatile</>.
5635       </para>
5636      </listitem>
5637
5638      <listitem>
5639       <para>
5640        Add system views <link
5641        linkend="view-pg-prepared-statements"><literal>pg_prepared_statements</></link>
5642        and <link
5643        linkend="view-pg-cursors"><literal>pg_cursors</></link>
5644        to show prepared statements and open cursors (Joachim Wieland, Neil)
5645       </para>
5646
5647       <para>
5648        These are very useful in pooled connection setups.
5649       </para>
5650      </listitem>
5651
5652      <listitem>
5653       <para>
5654        Support portal parameters in <link
5655        linkend="SQL-EXPLAIN"><command>EXPLAIN</></link> and <link
5656        linkend="SQL-EXECUTE"><command>EXECUTE</></link> (Tom)
5657       </para>
5658
5659       <para>
5660        This allows, for example, <acronym>JDBC</> <literal>?</> parameters to
5661        work in these commands.
5662       </para>
5663      </listitem>
5664
5665      <listitem>
5666       <para>
5667        If <acronym>SQL</>-level <link
5668        linkend="SQL-PREPARE"><command>PREPARE</></link> parameters
5669        are unspecified, infer their types from the content of the
5670        query (Neil)
5671       </para>
5672
5673       <para>
5674        Protocol-level <command>PREPARE</> already did this.
5675       </para>
5676      </listitem>
5677
5678      <listitem>
5679       <para>
5680        Allow <literal>LIMIT</> and <literal>OFFSET</> to exceed
5681        two billion (Dhanaraj M)
5682       </para>
5683      </listitem>
5684
5685     </itemizedlist>
5686
5687    </sect3>
5688
5689    <sect3>
5690     <title>Object Manipulation Changes</title>
5691     <itemizedlist>
5692
5693      <listitem>
5694       <para>
5695        Add <literal>TABLESPACE</> clause to <link
5696        linkend="SQL-CREATETABLEAS"><command>CREATE TABLE AS</></link>
5697        (Neil)
5698       </para>
5699
5700       <para>
5701        This allows a tablespace to be specified for the new table.
5702       </para>
5703      </listitem>
5704
5705      <listitem>
5706       <para>
5707        Add <literal>ON COMMIT</> clause to <link
5708        linkend="SQL-CREATETABLEAS"><command>CREATE TABLE AS</></link>
5709        (Neil)
5710       </para>
5711
5712       <para>
5713        This allows temporary tables to be truncated or dropped on
5714        transaction commit.  The default behavior is for the table
5715        to remain until the session ends.
5716       </para>
5717      </listitem>
5718
5719      <listitem>
5720       <para>
5721        Add <literal>INCLUDING CONSTRAINTS</> to <link
5722        linkend="SQL-CREATETABLE"><command>CREATE TABLE LIKE</></link>
5723        (Greg Stark)
5724       </para>
5725
5726       <para>
5727        This allows easy copying of <literal>CHECK</> constraints to a new
5728        table.
5729       </para>
5730      </listitem>
5731
5732      <listitem>
5733       <para>
5734        Allow the creation of placeholder (shell) <link
5735        linkend="SQL-CREATETYPE">types</link> (Martijn van Oosterhout)
5736       </para>
5737
5738       <para>
5739        A shell type declaration creates a type name, without specifying
5740        any of the details of the type.  Making a shell type is useful
5741        because it allows cleaner declaration of the type's input/output
5742        functions, which must exist before the type can be defined <quote>for
5743        real</>.  The syntax is <command>CREATE TYPE <replaceable
5744        class="parameter">typename</replaceable></>.
5745       </para>
5746      </listitem>
5747
5748      <listitem>
5749       <para>
5750        <link linkend="SQL-CREATEAGGREGATE">Aggregate functions</link>
5751        now support multiple input parameters (Sergey Koposov, Tom)
5752       </para>
5753      </listitem>
5754
5755      <listitem>
5756       <para>
5757        Add new aggregate creation <link
5758        linkend="SQL-CREATEAGGREGATE">syntax</link> (Tom)
5759       </para>
5760
5761       <para>
5762        The new syntax is <command>CREATE AGGREGATE
5763        <replaceable>aggname</> (<replaceable>input_type</>)
5764        (<replaceable>parameter_list</>)</command>.  This more
5765        naturally supports the new multi-parameter aggregate
5766        functionality.  The previous syntax is still supported.
5767       </para>
5768      </listitem>
5769
5770      <listitem>
5771       <para>
5772        Add <link
5773        linkend="SQL-ALTERROLE"><command>ALTER ROLE PASSWORD NULL</></link>
5774        to remove a previously set role password (Peter)
5775       </para>
5776      </listitem>
5777
5778      <listitem>
5779       <para>
5780        Add <command>DROP</> object <literal>IF EXISTS</> for many
5781        object types (Andrew)
5782       </para>
5783
5784       <para>
5785        This allows <command>DROP</> operations on non-existent
5786        objects without generating an error.
5787       </para>
5788      </listitem>
5789
5790      <listitem>
5791       <para>
5792        Add <link linkend="SQL-DROP-OWNED"><literal>DROP OWNED</></link>
5793        to drop all objects owned by a role (Alvaro)
5794       </para>
5795      </listitem>
5796
5797      <listitem>
5798       <para>
5799        Add <link linkend="SQL-REASSIGN-OWNED"><literal>REASSIGN
5800        OWNED</></link> to reassign ownership of all objects owned
5801        by a role (Alvaro)
5802       </para>
5803
5804       <para>
5805        This, and <literal>DROP OWNED</> above, facilitate dropping
5806        roles.
5807       </para>
5808      </listitem>
5809
5810      <listitem>
5811       <para>
5812        Add <link linkend="SQL-GRANT"><command>GRANT ON SEQUENCE</></link>
5813        syntax (Bruce)
5814       </para>
5815
5816       <para>
5817        This was added for setting sequence-specific permissions.
5818        <literal>GRANT ON TABLE</> for sequences is still supported
5819        for backward compatibility.
5820       </para>
5821      </listitem>
5822
5823      <listitem>
5824       <para>
5825        Add <link linkend="SQL-GRANT"><literal>USAGE</></link>
5826        permission for sequences that allows only <function>currval()</>
5827        and <function>nextval()</>, not <function>setval()</>
5828        (Bruce)
5829       </para>
5830
5831       <para>
5832        <literal>USAGE</> permission allows more fine-grained
5833        control over sequence access.  Granting <literal>USAGE</>
5834        allows users to increment
5835        a sequence, but prevents them from setting the sequence to
5836        an arbitrary value using <function>setval()</>.
5837       </para>
5838      </listitem>
5839
5840      <listitem>
5841       <para>
5842        Add <link linkend="SQL-ALTERTABLE"><literal>ALTER TABLE
5843        [ NO ] INHERIT</></link> (Greg Stark)
5844       </para>
5845
5846       <para>
5847        This allows inheritance to be adjusted dynamically, rather than
5848        just at table creation and destruction.  This is very valuable
5849        when using inheritance to implement table partitioning.
5850       </para>
5851      </listitem>
5852
5853      <listitem>
5854       <para>
5855        Allow <link linkend="SQL-COMMENT">comments</link> on global
5856        objects to be stored globally (Kris Jurka)
5857       </para>
5858
5859       <para>
5860        Previously, comments attached to databases were stored in individual
5861        databases, making them ineffective, and there was no provision
5862        at all for comments on roles or tablespaces.  This change adds a new
5863        shared catalog <link
5864        linkend="catalog-pg-shdescription"><structname>pg_shdescription</structname></link>
5865        and stores comments on databases, roles, and tablespaces therein.
5866       </para>
5867      </listitem>
5868
5869     </itemizedlist>
5870
5871    </sect3>
5872
5873    <sect3>
5874     <title>Utility Command Changes</title>
5875     <itemizedlist>
5876
5877      <listitem>
5878       <para>
5879        Add option to allow indexes to be created without blocking
5880        concurrent writes to the table (Greg Stark, Tom)
5881       </para>
5882
5883       <para>
5884        The new syntax is <link linkend="SQL-CREATEINDEX"><command>CREATE
5885        INDEX CONCURRENTLY</></link>.  The default behavior is
5886        still to block table modification while an index is being
5887        created.
5888       </para>
5889      </listitem>
5890
5891      <listitem>
5892       <para>
5893        Provide <link linkend="functions-advisory-locks">advisory
5894        locking</link> functionality (Abhijit Menon-Sen, Tom)
5895       </para>
5896
5897       <para>
5898        This is a new locking API designed to replace what used to be
5899        in /contrib/userlock.  The userlock code is now on pgfoundry.
5900       </para>
5901      </listitem>
5902
5903      <listitem>
5904       <para>
5905        Allow <link linkend="SQL-COPY"><command>COPY</></link> to
5906        dump a <command>SELECT</> query (Zoltan Boszormenyi, Karel
5907        Zak)
5908       </para>
5909
5910       <para>
5911        This allows <command>COPY</> to dump arbitrary <acronym>SQL</>
5912        queries. The syntax is <literal>COPY (SELECT ...) TO</>.
5913       </para>
5914      </listitem>
5915
5916      <listitem>
5917       <para>
5918        Make the <link linkend="SQL-COPY"><command>COPY</></link>
5919        command return a command tag that includes the number of
5920        rows copied (Volkan YAZICI)
5921       </para>
5922      </listitem>
5923
5924      <listitem>
5925       <para>
5926        Allow <link linkend="SQL-VACUUM"><command>VACUUM</></link>
5927        to expire rows without being affected by other concurrent
5928        <command>VACUUM</> operations (Hannu Krossing, Alvaro, Tom)
5929       </para>
5930      </listitem>
5931
5932      <listitem>
5933       <para>
5934        Make <link linkend="APP-INITDB"><application>initdb</></link>
5935        detect the operating system locale and set the default
5936        <varname>DateStyle</> accordingly (Peter)
5937       </para>
5938
5939       <para>
5940        This makes it more likely that the installed
5941        <filename>postgresql.conf</> <varname>DateStyle</> value will
5942        be as desired.
5943       </para>
5944      </listitem>
5945
5946      <listitem>
5947       <para>
5948        Reduce number of progress messages displayed by <application>initdb</> (Tom)
5949       </para>
5950      </listitem>
5951
5952     </itemizedlist>
5953
5954    </sect3>
5955
5956    <sect3>
5957     <title>Date/Time Changes</title>
5958     <itemizedlist>
5959
5960      <listitem>
5961       <para>
5962        Allow full timezone names in <link
5963        linkend="datatype-datetime"><type>timestamp</></link> input values
5964        (Joachim Wieland)
5965       </para>
5966
5967       <para>
5968        For example, <literal>'2006-05-24 21:11
5969        America/New_York'::timestamptz</>.
5970       </para>
5971      </listitem>
5972
5973      <listitem>
5974       <para>
5975        Support configurable timezone abbreviations (Joachim Wieland)
5976       </para>
5977
5978       <para>
5979        A desired set of timezone abbreviations can be chosen via the
5980        configuration parameter <link
5981        linkend="guc-timezone-abbreviations"><varname>timezone_abbreviations</></link>.
5982       </para>
5983      </listitem>
5984
5985      <listitem>
5986       <para>
5987        Add <link
5988        linkend="view-pg-timezone-abbrevs"><varname>pg_timezone_abbrevs</></link>
5989        and <link
5990        linkend="view-pg-timezone-names"><varname>pg_timezone_names</></link>
5991        views to show supported timezones (Magnus Hagander)
5992       </para>
5993      </listitem>
5994
5995      <listitem>
5996       <para>
5997        Add <link
5998        linkend="functions-datetime-table"><function>clock_timestamp()</></link>,
5999        <link
6000        linkend="functions-datetime-table"><function>statement_timestamp()</></link>,
6001        and <link
6002        linkend="functions-datetime-table"><function>transaction_timestamp()</></link>
6003        (Bruce)
6004       </para>
6005
6006       <para>
6007        <function>clock_timestamp()</> is the current wall-clock time,
6008        <function>statement_timestamp()</> is the time the current
6009        statement arrived at the server, and
6010        <function>transaction_timestamp()</> is an alias for
6011        <function>now()</>.
6012       </para>
6013      </listitem>
6014
6015      <listitem>
6016       <para>
6017        Allow <link
6018        linkend="functions-formatting"><function>to_char()</></link>
6019        to print localized month and day names (Euler Taveira de
6020        Oliveira)
6021       </para>
6022      </listitem>
6023
6024      <listitem>
6025       <para>
6026        Allow <link
6027        linkend="functions-formatting"><function>to_char(time)</></link>
6028        and <link
6029        linkend="functions-formatting"><function>to_char(interval)</></link>
6030        to output <acronym>AM</>/<acronym>PM</> specifications
6031        (Bruce)
6032       </para>
6033
6034       <para>
6035        Intervals and times are treated as 24-hour periods, e.g.
6036        <literal>25 hours</> is considered <acronym>AM</>.
6037       </para>
6038      </listitem>
6039
6040      <listitem>
6041       <para>
6042        Add new function <link
6043        linkend="functions-datetime-table"><function>justify_interval()</></link>
6044        to adjust interval units (Mark Dilger)
6045       </para>
6046      </listitem>
6047
6048      <listitem>
6049       <para>
6050        Allow timezone offsets up to 14:59 away from GMT
6051       </para>
6052
6053       <para>
6054        Kiribati uses GMT+14, so we'd better accept that.
6055       </para>
6056      </listitem>
6057
6058      <listitem>
6059       <para>
6060        Interval computation improvements (Michael Glaesemann, Bruce)
6061       </para>
6062      </listitem>
6063
6064     </itemizedlist>
6065
6066    </sect3>
6067
6068    <sect3>
6069     <title>Other Data Type and Function Changes</title>
6070     <itemizedlist>
6071
6072      <listitem>
6073       <para>
6074        Allow arrays to contain <literal>NULL</> elements (Tom)
6075       </para>
6076      </listitem>
6077
6078      <listitem>
6079       <para>
6080        Allow assignment to array elements not contiguous with the existing
6081        entries (Tom)
6082       </para>
6083
6084       <para>
6085        The intervening array positions will be filled with nulls.
6086        This is per SQL standard.
6087       </para>
6088      </listitem>
6089
6090      <listitem>
6091       <para>
6092        New built-in <link linkend="functions-array">operators</link>
6093        for array-subset comparisons (<literal>@&gt;</>,
6094        <literal>&lt;@</>, <literal>&amp;&amp;</>) (Teodor, Tom)
6095       </para>
6096
6097       <para>
6098        These operators can be indexed for many data types using
6099        <acronym>GiST</> or <acronym>GIN</> indexes.
6100       </para>
6101      </listitem>
6102
6103      <listitem>
6104       <para>
6105        Add convenient arithmetic <link
6106        linkend="cidr-inet-operators-table">operations</link> on
6107        <type>INET</>/<type>CIDR</> values (Stephen R. van den
6108        Berg)
6109       </para>
6110
6111       <para>
6112        The new operators are <literal>&amp;</> (and), <literal>|</>
6113        (or), <literal>~</> (not), <type>inet</> <literal>+</> <type>int8</>,
6114        <type>inet</> <literal>-</> <type>int8</>, and
6115        <type>inet</> <literal>-</> <type>inet</>.
6116       </para>
6117      </listitem>
6118
6119      <listitem>
6120       <para>
6121        Add new <link
6122        linkend="functions-aggregate-statistics-table">aggregate functions</link>
6123        from SQL:2003 (Neil)
6124       </para>
6125
6126       <para>
6127        The new functions are <function>var_pop()</>,
6128        <function>var_samp()</>, <function>stddev_pop()</>, and
6129        <function>stddev_samp()</>.  <function>var_samp()</> and
6130        <function>stddev_samp()</> are merely renamings of the
6131        existing aggregates <function>variance()</> and
6132        <function>stddev()</>.  The latter names remain available
6133        for backward compatibility.
6134       </para>
6135      </listitem>
6136
6137      <listitem>
6138       <para>
6139        Add SQL:2003 statistical <link
6140        linkend="functions-aggregate-statistics-table">aggregates</link>
6141        (Sergey Koposov)
6142       </para>
6143
6144       <para>
6145        New functions:  <function>regr_intercept()</>,
6146        <function>regr_slope()</>, <function>regr_r2()</>,
6147        <function>corr()</>, <function>covar_samp()</>,
6148        <function>covar_pop()</>, <function>regr_avgx()</>,
6149        <function>regr_avgy()</>, <function>regr_sxy()</>,
6150        <function>regr_sxx()</>, <function>regr_syy()</>,
6151        <function>regr_count()</>.
6152       </para>
6153      </listitem>
6154
6155      <listitem>
6156       <para>
6157        Allow <link linkend="SQL-CREATEDOMAIN">domains</link> to be
6158        based on other domains (Tom)
6159       </para>
6160      </listitem>
6161
6162      <listitem>
6163       <para>
6164        Properly enforce domain <link
6165        linkend="ddl-constraints"><literal>CHECK</></link> constraints
6166        everywhere (Neil, Tom)
6167       </para>
6168
6169       <para>
6170        For example, the result of a user-defined function that is
6171        declared to return a domain type is now checked against the
6172        domain's constraints. This closes a significant hole in the domain
6173        implementation.
6174       </para>
6175      </listitem>
6176
6177      <listitem>
6178       <para>
6179        Fix problems with dumping renamed <link
6180        linkend="datatype-serial"><type>SERIAL</></link> columns
6181        (Tom)
6182       </para>
6183
6184       <para>
6185        The fix is to dump a <type>SERIAL</> column by explicitly
6186        specifying its <literal>DEFAULT</> and sequence elements,
6187        and reconstructing the <type>SERIAL</> column on reload
6188        using a new <link linkend="SQL-ALTERSEQUENCE"><command>ALTER
6189        SEQUENCE OWNED BY</></link> command.  This also allows
6190        dropping a <type>SERIAL</> column specification.
6191       </para>
6192      </listitem>
6193
6194      <listitem>
6195       <para>
6196        Add a server-side sleep function <link
6197        linkend="functions-datetime-delay"><function>pg_sleep()</></link>
6198        (Joachim Wieland)
6199       </para>
6200      </listitem>
6201
6202      <listitem>
6203       <para>
6204        Add all comparison operators for the <link
6205        linkend="datatype-oid"><type>tid</></link> (tuple id) data
6206        type (Mark Kirkwood, Greg Stark, Tom)
6207       </para>
6208      </listitem>
6209
6210     </itemizedlist>
6211
6212    </sect3>
6213
6214    <sect3>
6215     <title>PL/pgSQL Server-Side Language Changes</title>
6216     <itemizedlist>
6217
6218      <listitem>
6219       <para>
6220        Add <literal>TG_table_name</> and <literal>TG_table_schema</> to
6221        trigger parameters (Andrew)
6222       </para>
6223
6224       <para>
6225        <literal>TG_relname</> is now deprecated.  Comparable
6226        changes have been made in the trigger parameters for the other
6227        PLs as well.
6228       </para>
6229      </listitem>
6230
6231      <listitem>
6232       <para>
6233        Allow <literal>FOR</> statements to return values to scalars
6234        as well as records and row types (Pavel Stehule)
6235       </para>
6236      </listitem>
6237
6238      <listitem>
6239       <para>
6240        Add a <literal>BY</> clause to the <literal>FOR</> loop,
6241        to control the iteration increment (Jaime Casanova)
6242       </para>
6243      </listitem>
6244
6245      <listitem>
6246       <para>
6247        Add <literal>STRICT</> to <link
6248        linkend="plpgsql-statements-sql-onerow"><command>SELECT
6249        INTO</></link> (Matt Miller)
6250       </para>
6251
6252       <para>
6253        <literal>STRICT</> mode throws an exception if more or less
6254        than one row is returned by the <command>SELECT</>, for
6255        <productname>Oracle PL/SQL</> compatibility.
6256       </para>
6257      </listitem>
6258
6259     </itemizedlist>
6260
6261    </sect3>
6262
6263    <sect3>
6264     <title>PL/Perl Server-Side Language Changes</title>
6265     <itemizedlist>
6266
6267      <listitem>
6268       <para>
6269        Add <literal>table_name</> and <literal>table_schema</> to
6270        trigger parameters (Adam Sj&oslash;gren)
6271       </para>
6272      </listitem>
6273
6274      <listitem>
6275       <para>
6276        Add prepared queries (Dmitry Karasik)
6277       </para>
6278      </listitem>
6279
6280      <listitem>
6281       <para>
6282        Make <literal>$_TD</> trigger data a global variable (Andrew)
6283       </para>
6284
6285       <para>
6286        Previously, it was lexical, which caused unexpected sharing
6287        violations.
6288       </para>
6289      </listitem>
6290
6291      <listitem>
6292       <para>
6293        Run PL/Perl and PL/PerlU in separate interpreters, for security
6294        reasons (Andrew)
6295       </para>
6296       <para>
6297        In consequence, they can no longer share data nor loaded modules.
6298        Also, if Perl has not been compiled with the requisite flags to
6299        allow multiple interpreters, only one of these languages can be used
6300        in any given backend process.
6301       </para>
6302      </listitem>
6303
6304     </itemizedlist>
6305
6306    </sect3>
6307
6308    <sect3>
6309     <title>PL/Python Server-Side Language Changes</title>
6310     <itemizedlist>
6311
6312      <listitem>
6313       <para>
6314        Named parameters are passed as ordinary variables, as well as in the
6315        <literal>args[]</> array (Sven Suursoho)
6316       </para>
6317      </listitem>
6318
6319      <listitem>
6320       <para>
6321        Add <literal>table_name</> and <literal>table_schema</> to
6322        trigger parameters (Andrew)
6323       </para>
6324      </listitem>
6325
6326      <listitem>
6327       <para>
6328        Allow returning of composite types and result sets (Sven Suursoho)
6329       </para>
6330      </listitem>
6331
6332      <listitem>
6333       <para>
6334        Return result-set as <literal>list</>, <literal>iterator</>,
6335        or <literal>generator </>(Sven Suursoho)
6336       </para>
6337      </listitem>
6338
6339      <listitem>
6340       <para>
6341        Allow functions to return <literal>void</> (Neil)
6342       </para>
6343      </listitem>
6344
6345      <listitem>
6346       <para>
6347        Python 2.5 is now supported (Tom)
6348       </para>
6349      </listitem>
6350
6351     </itemizedlist>
6352
6353    </sect3>
6354
6355    <sect3>
6356     <title><link linkend="APP-PSQL"><application>psql</></link> Changes</title>
6357     <itemizedlist>
6358
6359      <listitem>
6360       <para>
6361        Add new command <literal>\password</> for changing role
6362        password with client-side password encryption (Peter)
6363       </para>
6364      </listitem>
6365
6366      <listitem>
6367       <para>
6368        Allow <literal>\c</> to connect to a new host and port
6369        number (David, Volkan YAZICI)
6370       </para>
6371      </listitem>
6372
6373      <listitem>
6374       <para>
6375        Add tablespace display to <literal>\l+</> (Philip Yarra)
6376       </para>
6377      </listitem>
6378
6379      <listitem>
6380       <para>
6381        Improve <literal>\df</> slash command to include the argument
6382        names and modes (<literal>OUT</> or <literal>INOUT</>) of
6383        the function (David Fetter)
6384       </para>
6385      </listitem>
6386
6387      <listitem>
6388       <para>
6389        Support binary <command>COPY</> (Andreas Pflug)
6390       </para>
6391      </listitem>
6392
6393      <listitem>
6394       <para>
6395        Add option to run the entire session in a single transaction
6396        (Simon)
6397       </para>
6398
6399       <para>
6400        Use option <literal>-1</> or <literal>--single-transaction</>.
6401       </para>
6402      </listitem>
6403
6404      <listitem>
6405       <para>
6406        Support for automatically retrieving <command>SELECT</>
6407        results in batches using a cursor (Chris Mair)
6408       </para>
6409
6410       <para>
6411        This is enabled using <command>\set FETCH_COUNT
6412        <replaceable>n</></command>. This
6413        feature allows large result sets to be retrieved in
6414        <application>psql</> without attempting to buffer the entire
6415        result set in memory.
6416       </para>
6417      </listitem>
6418
6419      <listitem>
6420       <para>
6421        Make multi-line values align in the proper column
6422        (Martijn van Oosterhout)
6423       </para>
6424
6425       <para>
6426        Field values containing newlines are now displayed in a more
6427        readable fashion.
6428       </para>
6429      </listitem>
6430
6431      <listitem>
6432       <para>
6433        Save multi-line statements as a single entry, rather than
6434        one line at a time (Sergey E. Koposov)
6435       </para>
6436
6437       <para>
6438        This makes up-arrow recall of queries easier.  (This is
6439        not available on Windows, because that platform uses the native
6440        command-line editing present in the operating system.)
6441       </para>
6442      </listitem>
6443
6444      <listitem>
6445       <para>
6446        Make the line counter 64-bit so it can handle files with more
6447        than two billion lines (David Fetter)
6448       </para>
6449      </listitem>
6450
6451      <listitem>
6452       <para>
6453        Report both the returned data and the command status tag
6454        for <command>INSERT</>/<command>UPDATE</>/<command>DELETE
6455        RETURNING</> (Tom)
6456       </para>
6457      </listitem>
6458
6459     </itemizedlist>
6460
6461    </sect3>
6462
6463    <sect3>
6464     <title><link linkend="APP-PGDUMP"><application>pg_dump</></link> Changes</title>
6465     <itemizedlist>
6466
6467      <listitem>
6468       <para>
6469        Allow complex selection of objects to be included or excluded
6470        by <application>pg_dump</> (Greg Sabino Mullane)
6471       </para>
6472
6473       <para>
6474        <application>pg_dump</> now supports multiple <literal>-n</>
6475        (schema) and <literal>-t</> (table) options, and adds
6476        <literal>-N</> and <literal>-T</> options to exclude objects.
6477        Also, the arguments of these switches can now be wild-card expressions
6478        rather than single object names, for example
6479        <literal>-t 'foo*'</>, and a schema can be part of
6480        a <literal>-t</> or <literal>-T</> switch, for example
6481        <literal>-t schema1.table1</>.
6482       </para>
6483      </listitem>
6484
6485      <listitem>
6486       <para>
6487        Add <link linkend="APP-PGRESTORE"><application>pg_restore</></link>
6488        <literal>--no-data-for-failed-tables</> option to suppress
6489        loading data if table creation failed (i.e., the table already
6490        exists) (Martin Pitt)
6491       </para>
6492      </listitem>
6493
6494      <listitem>
6495       <para>
6496        Add <link linkend="APP-PGRESTORE"><application>pg_restore</></link>
6497        option to run the entire session in a single transaction
6498        (Simon)
6499       </para>
6500
6501       <para>
6502        Use option <literal>-1</> or <literal>--single-transaction</>.
6503       </para>
6504      </listitem>
6505
6506     </itemizedlist>
6507
6508    </sect3>
6509
6510    <sect3>
6511     <title><link linkend="libpq"><application>libpq</></link> Changes</title>
6512     <itemizedlist>
6513
6514      <listitem>
6515       <para>
6516        Add <link
6517        linkend="libpq-misc"><function>PQencryptPassword()</></link>
6518        to encrypt passwords (Tom)
6519       </para>
6520
6521       <para>
6522        This allows passwords to be sent pre-encrypted for commands
6523        like <link linkend="SQL-ALTERROLE"><command>ALTER ROLE ...
6524        PASSWORD</></link>.
6525       </para>
6526      </listitem>
6527
6528      <listitem>
6529       <para>
6530        Add function <link
6531        linkend="libpq-threading"><function>PQisthreadsafe()</></link>
6532        (Bruce)
6533       </para>
6534
6535       <para>
6536        This allows applications to query the thread-safety status
6537        of the library.
6538       </para>
6539      </listitem>
6540
6541      <listitem>
6542       <para>
6543        Add <link
6544        linkend="libpq-exec-main"><function>PQdescribePrepared()</></link>,
6545        <link
6546        linkend="libpq-exec-main"><function>PQdescribePortal()</></link>,
6547        and related functions to return information about previously
6548        prepared statements and open cursors (Volkan YAZICI)
6549       </para>
6550      </listitem>
6551
6552      <listitem>
6553       <para>
6554        Allow <link linkend="libpq-ldap"><acronym>LDAP</></link> lookups
6555        from <link
6556        linkend="libpq-pgservice"><filename>pg_service.conf</></link>
6557        (Laurenz Albe)
6558       </para>
6559      </listitem>
6560
6561      <listitem>
6562       <para>
6563        Allow a hostname in <link
6564        linkend="libpq-pgpass"><filename>~/.pgpass</></link>
6565        to match the default socket directory (Bruce)
6566       </para>
6567
6568       <para>
6569        A blank hostname continues to match any Unix-socket connection,
6570        but this addition allows entries that are specific to one of
6571        several postmasters on the machine.
6572       </para>
6573      </listitem>
6574
6575     </itemizedlist>
6576
6577    </sect3>
6578
6579    <sect3>
6580     <title><link linkend="ecpg"><application>ecpg</></link> Changes</title>
6581     <itemizedlist>
6582
6583      <listitem>
6584       <para>
6585        Allow <link linkend="SQL-SHOW"><command>SHOW</></link> to
6586        put its result into a variable (Joachim Wieland)
6587       </para>
6588      </listitem>
6589
6590      <listitem>
6591       <para>
6592        Add <link linkend="SQL-COPY"><command>COPY TO STDOUT</></link>
6593        (Joachim Wieland)
6594       </para>
6595      </listitem>
6596
6597      <listitem>
6598       <para>
6599        Add regression tests (Joachim Wieland, Michael)
6600       </para>
6601      </listitem>
6602
6603      <listitem>
6604       <para>
6605        Major source code cleanups (Joachim Wieland, Michael)
6606       </para>
6607      </listitem>
6608
6609     </itemizedlist>
6610
6611    </sect3>
6612
6613    <sect3>
6614     <title><application>Windows</> Port</title>
6615     <itemizedlist>
6616
6617      <listitem>
6618       <para>
6619        Allow <acronym>MSVC</> to compile the <productname>PostgreSQL</>
6620        server (Magnus, Hiroshi Saito)
6621       </para>
6622      </listitem>
6623
6624      <listitem>
6625       <para>
6626        Add <acronym>MSVC</> support for utility commands and <link
6627        linkend="APP-PGDUMP"><application>pg_dump</></link> (Hiroshi
6628        Saito)
6629       </para>
6630      </listitem>
6631
6632      <listitem>
6633       <para>
6634        Add support for Windows code pages <literal>1253</>,
6635        <literal>1254</>, <literal>1255</>, and <literal>1257</>
6636        (Kris Jurka)
6637       </para>
6638      </listitem>
6639
6640      <listitem>
6641       <para>
6642        Drop privileges on startup, so that the server can be started from
6643        an administrative account (Magnus)
6644       </para>
6645      </listitem>
6646
6647      <listitem>
6648       <para>
6649        Stability fixes (Qingqing Zhou, Magnus)
6650       </para>
6651      </listitem>
6652
6653      <listitem>
6654       <para>
6655        Add native semaphore implementation (Qingqing Zhou)
6656       </para>
6657
6658       <para>
6659        The previous code mimicked SysV semaphores.
6660       </para>
6661      </listitem>
6662
6663     </itemizedlist>
6664
6665    </sect3>
6666
6667    <sect3>
6668     <title>Source Code Changes</title>
6669     <itemizedlist>
6670
6671      <listitem>
6672       <para>
6673        Add <link linkend="GIN"><acronym>GIN</></link> (Generalized
6674        Inverted iNdex) index access method (Teodor, Oleg)
6675       </para>
6676      </listitem>
6677
6678      <listitem>
6679       <para>
6680        Remove R-tree indexing (Tom)
6681       </para>
6682
6683       <para>
6684        Rtree has been re-implemented using <link
6685        linkend="GiST"><acronym>GiST</></link>. Among other
6686        differences, this means that rtree indexes now have support
6687        for crash recovery via write-ahead logging (WAL).
6688       </para>
6689      </listitem>
6690
6691      <listitem>
6692       <para>
6693        Reduce libraries needlessly linked into the backend (Martijn
6694        van Oosterhout, Tom)
6695       </para>
6696      </listitem>
6697
6698      <listitem>
6699       <para>
6700        Add a configure flag to allow libedit to be preferred over
6701        <acronym>GNU</> readline (Bruce)
6702       </para>
6703
6704       <para>
6705        Use configure <link
6706        linkend="configure"><literal>--with-libedit-preferred</></link>.
6707       </para>
6708      </listitem>
6709
6710      <listitem>
6711       <para>
6712        Allow installation into directories containing spaces
6713        (Peter)
6714       </para>
6715      </listitem>
6716
6717      <listitem>
6718       <para>
6719        Improve ability to relocate installation directories (Tom)
6720       </para>
6721      </listitem>
6722
6723      <listitem>
6724       <para>
6725        Add support for <productname>Solaris x86_64</> using the
6726        <productname>Solaris</> compiler (Pierre Girard, Theo
6727        Schlossnagle, Bruce)
6728       </para>
6729      </listitem>
6730
6731      <listitem>
6732       <para>
6733        Add <application>DTrace</> support (Robert Lor)
6734       </para>
6735      </listitem>
6736
6737      <listitem>
6738       <para>
6739        Add <literal>PG_VERSION_NUM</> for use by third-party
6740        applications wanting to test the backend version in C using &gt;
6741        and &lt; comparisons (Bruce)
6742       </para>
6743      </listitem>
6744
6745      <listitem>
6746       <para>
6747        Add <literal>XLOG_BLCKSZ</> as independent from <literal>BLCKSZ</>
6748        (Mark Wong)
6749       </para>
6750      </listitem>
6751
6752      <listitem>
6753       <para>
6754        Add <literal>LWLOCK_STATS</> define to report locking
6755        activity (Tom)
6756       </para>
6757      </listitem>
6758
6759      <listitem>
6760       <para>
6761        Emit warnings for unknown <application>configure</> options
6762        (Martijn van Oosterhout)
6763       </para>
6764      </listitem>
6765
6766      <listitem>
6767       <para>
6768        Add server support for <quote>plugin</> libraries
6769        that can be used for add-on tasks such as debugging and performance
6770        measurement (Korry Douglas)
6771       </para>
6772
6773       <para>
6774        This consists of two features: a table of <quote>rendezvous
6775        variables</> that allows separately-loaded shared libraries to
6776        communicate, and a new configuration parameter <link
6777        linkend="guc-local-preload-libraries"><varname>local_preload_libraries</></link>
6778        that allows libraries to be loaded into specific sessions without
6779        explicit cooperation from the client application.  This allows
6780        external add-ons to implement features such as a PL/pgSQL debugger.
6781       </para>
6782      </listitem>
6783
6784      <listitem>
6785       <para>
6786        Rename existing configuration parameter
6787        <varname>preload_libraries</> to <link
6788        linkend="guc-shared-preload-libraries"><varname>shared_preload_libraries</></link>
6789        (Tom)
6790       </para>
6791
6792       <para>
6793        This was done for clarity in comparison to
6794        <varname>local_preload_libraries</>.
6795       </para>
6796      </listitem>
6797
6798      <listitem>
6799       <para>
6800        Add new configuration parameter <link
6801        linkend="guc-server-version-num"><varname>server_version_num</></link>
6802        (Greg Sabino Mullane)
6803       </para>
6804
6805       <para>
6806        This is like <varname>server_version</varname>, but is an
6807        integer, e.g.  <literal>80200</>. This allows applications to
6808        make version checks more easily.
6809       </para>
6810      </listitem>
6811
6812      <listitem>
6813       <para>
6814        Add a configuration parameter <link
6815        linkend="guc-seq-page-cost"><varname>seq_page_cost</></link>
6816        (Tom)
6817       </para>
6818      </listitem>
6819
6820      <listitem>
6821       <para>
6822        Re-implement the <link linkend="regress">regression test</link> script as a C program
6823        (Magnus, Tom)
6824       </para>
6825      </listitem>
6826
6827      <listitem>
6828       <para>
6829        Allow loadable modules to allocate shared memory and
6830        lightweight locks (Marc Munro)
6831       </para>
6832      </listitem>
6833
6834      <listitem>
6835       <para>
6836        Add automatic initialization and finalization of dynamically
6837        loaded libraries (Ralf Engelschall, Tom)
6838       </para>
6839
6840       <para>
6841        New <link linkend="xfunc-c-dynload">functions</link>
6842        <function>_PG_init()</> and <function>_PG_fini()</> are
6843        called if the library defines such symbols.  Hence we no
6844        longer need to specify an initialization function in
6845        <varname>shared_preload_libraries</>; we can assume that
6846        the library used the <function>_PG_init()</> convention
6847        instead.
6848       </para>
6849      </listitem>
6850
6851      <listitem>
6852       <para>
6853        Add <link
6854        linkend="xfunc-c-dynload"><literal>PG_MODULE_MAGIC</></link>
6855        header block to all shared object files (Martijn van
6856        Oosterhout)
6857       </para>
6858
6859       <para>
6860        The magic block prevents version mismatches between loadable object
6861        files and servers.
6862       </para>
6863      </listitem>
6864
6865      <listitem>
6866       <para>
6867         Add shared library support for AIX (Laurenz Albe)
6868       </para>
6869      </listitem>
6870
6871      <listitem>
6872       <para>
6873        New <link linkend="datatype-xml"><acronym>XML</></link>
6874        documentation section (Bruce)
6875       </para>
6876      </listitem>
6877
6878     </itemizedlist>
6879
6880    </sect3>
6881
6882    <sect3>
6883     <title>Contrib Changes</title>
6884     <itemizedlist>
6885
6886      <listitem>
6887       <para>
6888        Major tsearch2 improvements (Oleg, Teodor)
6889       </para>
6890
6891       <itemizedlist>
6892
6893        <listitem>
6894         <para>
6895          multibyte encoding support, including <acronym>UTF8</>
6896         </para>
6897        </listitem>
6898        <listitem>
6899         <para>
6900          query rewriting support
6901         </para>
6902        </listitem>
6903        <listitem>
6904         <para>
6905          improved ranking functions
6906         </para>
6907        </listitem>
6908        <listitem>
6909         <para>
6910          thesaurus dictionary support
6911         </para>
6912        </listitem>
6913        <listitem>
6914         <para>
6915          Ispell dictionaries now recognize <application>MySpell</>
6916          format, used by <application>OpenOffice</>
6917         </para>
6918        </listitem>
6919        <listitem>
6920         <para>
6921          <acronym>GIN</> support
6922         </para>
6923        </listitem>
6924
6925       </itemizedlist>
6926
6927      </listitem>
6928
6929      <listitem>
6930       <para>
6931        Add adminpack module containing <application>Pgadmin</> administration
6932        functions (Dave)
6933       </para>
6934
6935       <para>
6936        These functions provide additional file system access
6937        routines not present in the default <productname>PostgreSQL</>
6938        server.
6939       </para>
6940      </listitem>
6941
6942      <listitem>
6943       <para>
6944        Add sslinfo module (Victor Wagner)
6945       </para>
6946
6947       <para>
6948        Reports information about the current connection's <acronym>SSL</>
6949        certificate.
6950       </para>
6951      </listitem>
6952
6953      <listitem>
6954       <para>
6955        Add pgrowlocks module (Tatsuo)
6956       </para>
6957
6958       <para>
6959        This shows row locking information for a specified table.
6960       </para>
6961      </listitem>
6962
6963      <listitem>
6964       <para>
6965        Add hstore module (Oleg, Teodor)
6966       </para>
6967      </listitem>
6968
6969      <listitem>
6970       <para>
6971        Add isn module, replacing isbn_issn (Jeremy Kronuz)
6972       </para>
6973
6974       <para>
6975        This new implementation supports <acronym>EAN13</>, <acronym>UPC</>,
6976        <acronym>ISBN</> (books), <acronym>ISMN</> (music), and
6977        <acronym>ISSN</> (serials).
6978       </para>
6979      </listitem>
6980
6981      <listitem>
6982       <para>
6983        Add index information functions to pgstattuple (ITAGAKI Takahiro,
6984        Satoshi Nagayasu)
6985       </para>
6986      </listitem>
6987
6988      <listitem>
6989       <para>
6990        Add pg_freespacemap module to display free space map information
6991        (Mark Kirkwood)
6992       </para>
6993      </listitem>
6994
6995      <listitem>
6996       <para>
6997        pgcrypto now has all planned functionality (Marko Kreen)
6998       </para>
6999       <itemizedlist>
7000        <listitem>
7001         <para>
7002          Include iMath library in pgcrypto to have the public-key encryption
7003          functions always available.
7004         </para>
7005        </listitem>
7006        <listitem>
7007         <para>
7008          Add SHA224 algorithm that was missing in OpenBSD code.
7009         </para>
7010        </listitem>
7011        <listitem>
7012         <para>
7013          Activate builtin code for SHA224/256/384/512 hashes on older
7014          OpenSSL to have those algorithms always available.
7015         </para>
7016        </listitem>
7017        <listitem>
7018         <para>
7019          New function gen_random_bytes() that returns cryptographically strong
7020          randomness.  Useful for generating encryption keys.
7021         </para>
7022        </listitem>
7023        <listitem>
7024         <para>
7025          Remove digest_exists(), hmac_exists() and cipher_exists() functions.
7026         </para>
7027        </listitem>
7028       </itemizedlist>
7029      </listitem>
7030
7031      <listitem>
7032       <para>
7033        Improvements to cube module (Joshua Reich)
7034       </para>
7035
7036       <para>
7037        New functions are <function>cube(float[])</>,
7038        <function>cube(float[], float[])</>, and
7039        <function>cube_subset(cube, int4[])</>.
7040       </para>
7041      </listitem>
7042
7043      <listitem>
7044       <para>
7045        Add async query capability to dblink (Kai Londenberg,
7046        Joe Conway)
7047       </para>
7048      </listitem>
7049
7050      <listitem>
7051       <para>
7052        New operators for array-subset comparisons (<literal>@&gt;</>,
7053        <literal>&lt;@</>, <literal>&amp;&amp;</>) (Tom)
7054       </para>
7055
7056       <para>
7057        Various contrib packages already had these operators for their
7058        datatypes, but the naming wasn't consistent.  We have now added
7059        consistently named array-subset comparison operators to the core code
7060        and all the contrib packages that have such functionality.
7061        (The old names remain available, but are deprecated.)
7062       </para>
7063      </listitem>
7064
7065      <listitem>
7066       <para>
7067        Add uninstall scripts for all contrib packages that have install
7068        scripts (David, Josh Drake)
7069       </para>
7070      </listitem>
7071
7072     </itemizedlist>
7073
7074    </sect3>
7075
7076   </sect2>
7077  </sect1>