The code to unlink dropped relations in FinishPreparedTransaction() was
[PostgreSQL.git] / doc / src / sgml / release-8.2.sgml
blobceb87fac0c3b4d2fc0bcd5818cc21952de460ee6
1 <!-- $PostgreSQL$ -->
2 <!-- See header comment in release.sgml about typical markup -->
4 <sect1 id="release-8-2-13">
5 <title>Release 8.2.13</title>
7 <note>
8 <title>Release date</title>
9 <simpara>2009-03-16</simpara>
10 </note>
12 <para>
13 This release contains a variety of fixes from 8.2.12.
14 For information about new features in the 8.2 major release, see
15 <xref linkend="release-8-2">.
16 </para>
18 <sect2>
19 <title>Migration to Version 8.2.13</title>
21 <para>
22 A dump/restore is not required for those running 8.2.X.
23 However, if you are upgrading from a version earlier than 8.2.11,
24 see the release notes for 8.2.11.
25 </para>
27 </sect2>
29 <sect2>
30 <title>Changes</title>
32 <itemizedlist>
34 <listitem>
35 <para>
36 Prevent error recursion crashes when encoding conversion fails (Tom)
37 </para>
39 <para>
40 This change extends fixes made in the last two minor releases for
41 related failure scenarios. The previous fixes were narrowly tailored
42 for the original problem reports, but we have now recognized that
43 <emphasis>any</> error thrown by an encoding conversion function could
44 potentially lead to infinite recursion while trying to report the
45 error. The solution therefore is to disable translation and encoding
46 conversion and report the plain-ASCII form of any error message,
47 if we find we have gotten into a recursive error reporting situation.
48 (CVE-2009-0922)
49 </para>
50 </listitem>
52 <listitem>
53 <para>
54 Disallow <command>CREATE CONVERSION</> with the wrong encodings
55 for the specified conversion function (Heikki)
56 </para>
58 <para>
59 This prevents one possible scenario for encoding conversion failure.
60 The previous change is a backstop to guard against other kinds of
61 failures in the same area.
62 </para>
63 </listitem>
65 <listitem>
66 <para>
67 Fix core dump when <function>to_char()</> is given format codes that
68 are inappropriate for the type of the data argument (Tom)
69 </para>
70 </listitem>
72 <listitem>
73 <para>
74 Fix possible failure in <filename>contrib/tsearch2</> when C locale is
75 used with a multi-byte encoding (Teodor)
76 </para>
78 <para>
79 Crashes were possible on platforms where <type>wchar_t</> is narrower
80 than <type>int</>; Windows in particular.
81 </para>
82 </listitem>
84 <listitem>
85 <para>
86 Fix extreme inefficiency in <filename>contrib/tsearch2</> parser's
87 handling of an email-like string containing multiple <literal>@</>
88 characters (Heikki)
89 </para>
90 </listitem>
92 <listitem>
93 <para>
94 Fix decompilation of <literal>CASE WHEN</> with an implicit coercion
95 (Tom)
96 </para>
98 <para>
99 This mistake could lead to Assert failures in an Assert-enabled build,
100 or an <quote>unexpected CASE WHEN clause</> error message in other
101 cases, when trying to examine or dump a view.
102 </para>
103 </listitem>
105 <listitem>
106 <para>
107 Fix possible misassignment of the owner of a TOAST table's rowtype (Tom)
108 </para>
110 <para>
111 If <command>CLUSTER</> or a rewriting variant of <command>ALTER TABLE</>
112 were executed by someone other than the table owner, the
113 <structname>pg_type</> entry for the table's TOAST table would end up
114 marked as owned by that someone. This caused no immediate problems,
115 since the permissions on the TOAST rowtype aren't examined by any
116 ordinary database operation. However, it could lead to unexpected
117 failures if one later tried to drop the role that issued the command
118 (in 8.1 or 8.2), or <quote>owner of data type appears to be invalid</>
119 warnings from <application>pg_dump</> after having done so (in 8.3).
120 </para>
121 </listitem>
123 <listitem>
124 <para>
125 Fix PL/pgSQL to not treat <literal>INTO</> after <command>INSERT</> as
126 an INTO-variables clause anywhere in the string, not only at the start;
127 in particular, don't fail for <command>INSERT INTO</> within
128 <command>CREATE RULE</> (Tom)
129 </para>
130 </listitem>
132 <listitem>
133 <para>
134 Clean up PL/pgSQL error status variables fully at block exit
135 (Ashesh Vashi and Dave Page)
136 </para>
138 <para>
139 This is not a problem for PL/pgSQL itself, but the omission could cause
140 the PL/pgSQL Debugger to crash while examining the state of a function.
141 </para>
142 </listitem>
144 <listitem>
145 <para>
146 Retry failed calls to <function>CallNamedPipe()</> on Windows
147 (Steve Marshall, Magnus)
148 </para>
150 <para>
151 It appears that this function can sometimes fail transiently;
152 we previously treated any failure as a hard error, which could
153 confuse <command>LISTEN</>/<command>NOTIFY</> as well as other
154 operations.
155 </para>
156 </listitem>
158 <listitem>
159 <para>
160 Add <literal>MUST</> (Mauritius Island Summer Time) to the default list
161 of known timezone abbreviations (Xavier Bugaud)
162 </para>
163 </listitem>
165 </itemizedlist>
167 </sect2>
168 </sect1>
170 <sect1 id="release-8-2-12">
171 <title>Release 8.2.12</title>
173 <note>
174 <title>Release date</title>
175 <simpara>2009-02-02</simpara>
176 </note>
178 <para>
179 This release contains a variety of fixes from 8.2.11.
180 For information about new features in the 8.2 major release, see
181 <xref linkend="release-8-2">.
182 </para>
184 <sect2>
185 <title>Migration to Version 8.2.12</title>
187 <para>
188 A dump/restore is not required for those running 8.2.X.
189 However, if you are upgrading from a version earlier than 8.2.11,
190 see the release notes for 8.2.11.
191 </para>
193 </sect2>
195 <sect2>
196 <title>Changes</title>
198 <itemizedlist>
200 <listitem>
201 <para>
202 Improve handling of URLs in <function>headline()</> function (Teodor)
203 </para>
204 </listitem>
206 <listitem>
207 <para>
208 Improve handling of overlength headlines in <function>headline()</>
209 function (Teodor)
210 </para>
211 </listitem>
213 <listitem>
214 <para>
215 Prevent possible Assert failure or misconversion if an encoding
216 conversion is created with the wrong conversion function for the
217 specified pair of encodings (Tom, Heikki)
218 </para>
219 </listitem>
221 <listitem>
222 <para>
223 Fix possible Assert failure if a statement executed in PL/pgSQL is
224 rewritten into another kind of statement, for example if an
225 <command>INSERT</> is rewritten into an <command>UPDATE</> (Heikki)
226 </para>
227 </listitem>
229 <listitem>
230 <para>
231 Ensure that a snapshot is available to datatype input functions (Tom)
232 </para>
234 <para>
235 This primarily affects domains that are declared with <literal>CHECK</>
236 constraints involving user-defined stable or immutable functions. Such
237 functions typically fail if no snapshot has been set.
238 </para>
239 </listitem>
241 <listitem>
242 <para>
243 Make it safer for SPI-using functions to be used within datatype I/O;
244 in particular, to be used in domain check constraints (Tom)
245 </para>
246 </listitem>
248 <listitem>
249 <para>
250 Avoid unnecessary locking of small tables in <command>VACUUM</>
251 (Heikki)
252 </para>
253 </listitem>
255 <listitem>
256 <para>
257 Fix a problem that made <literal>UPDATE RETURNING tableoid</>
258 return zero instead of the correct OID (Tom)
259 </para>
260 </listitem>
262 <listitem>
263 <para>
264 Fix planner misestimation of selectivity when transitive equality
265 is applied to an outer-join clause (Tom)
266 </para>
268 <para>
269 This could result in bad plans for queries like
270 <literal>... from a left join b on a.a1 = b.b1 where a.a1 = 42 ...</>
271 </para>
272 </listitem>
274 <listitem>
275 <para>
276 Improve optimizer's handling of long <literal>IN</> lists (Tom)
277 </para>
279 <para>
280 This change avoids wasting large amounts of time on such lists
281 when constraint exclusion is enabled.
282 </para>
283 </listitem>
285 <listitem>
286 <para>
287 Ensure that the contents of a holdable cursor don't depend on the
288 contents of TOAST tables (Tom)
289 </para>
291 <para>
292 Previously, large field values in a cursor result might be represented
293 as TOAST pointers, which would fail if the referenced table got dropped
294 before the cursor is read, or if the large value is deleted and then
295 vacuumed away. This cannot happen with an ordinary cursor,
296 but it could with a cursor that is held past its creating transaction.
297 </para>
298 </listitem>
300 <listitem>
301 <para>
302 Fix memory leak when a set-returning function is terminated without
303 reading its whole result (Tom)
304 </para>
305 </listitem>
307 <listitem>
308 <para>
309 Fix <filename>contrib/dblink</>'s
310 <function>dblink_get_result(text,bool)</> function (Joe)
311 </para>
312 </listitem>
314 <listitem>
315 <para>
316 Fix possible garbage output from <filename>contrib/sslinfo</> functions
317 (Tom)
318 </para>
319 </listitem>
321 <listitem>
322 <para>
323 Fix <application>configure</> script to properly report failure when
324 unable to obtain linkage information for PL/Perl (Andrew)
325 </para>
326 </listitem>
328 <listitem>
329 <para>
330 Make all documentation reference <literal>pgsql-bugs</> and/or
331 <literal>pgsql-hackers</> as appropriate, instead of the
332 now-decommissioned <literal>pgsql-ports</> and <literal>pgsql-patches</>
333 mailing lists (Tom)
334 </para>
335 </listitem>
337 <listitem>
338 <para>
339 Update time zone data files to <application>tzdata</> release 2009a (for
340 Kathmandu and historical DST corrections in Switzerland, Cuba)
341 </para>
342 </listitem>
344 </itemizedlist>
346 </sect2>
347 </sect1>
349 <sect1 id="release-8-2-11">
350 <title>Release 8.2.11</title>
352 <note>
353 <title>Release date</title>
354 <simpara>2008-11-03</simpara>
355 </note>
357 <para>
358 This release contains a variety of fixes from 8.2.10.
359 For information about new features in the 8.2 major release, see
360 <xref linkend="release-8-2">.
361 </para>
363 <sect2>
364 <title>Migration to Version 8.2.11</title>
366 <para>
367 A dump/restore is not required for those running 8.2.X.
368 However, if you are upgrading from a version earlier than 8.2.7,
369 see the release notes for 8.2.7. Also, if you were running a previous
370 8.2.X release, it is recommended to <command>REINDEX</> all GiST
371 indexes after the upgrade.
372 </para>
374 </sect2>
376 <sect2>
377 <title>Changes</title>
379 <itemizedlist>
381 <listitem>
382 <para>
383 Fix GiST index corruption due to marking the wrong index entry
384 <quote>dead</> after a deletion (Teodor)
385 </para>
387 <para>
388 This would result in index searches failing to find rows they
389 should have found. Corrupted indexes can be fixed with
390 <command>REINDEX</>.
391 </para>
392 </listitem>
394 <listitem>
395 <para>
396 Fix backend crash when the client encoding cannot represent a localized
397 error message (Tom)
398 </para>
400 <para>
401 We have addressed similar issues before, but it would still fail if
402 the <quote>character has no equivalent</> message itself couldn't
403 be converted. The fix is to disable localization and send the plain
404 ASCII error message when we detect such a situation.
405 </para>
406 </listitem>
408 <listitem>
409 <para>
410 Fix possible crash when deeply nested functions are invoked from
411 a trigger (Tom)
412 </para>
413 </listitem>
415 <listitem>
416 <para>
417 Improve optimization of <replaceable>expression</> <literal>IN</>
418 (<replaceable>expression-list</>) queries (Tom, per an idea from Robert
419 Haas)
420 </para>
422 <para>
423 Cases in which there are query variables on the right-hand side had been
424 handled less efficiently in 8.2.x and 8.3.x than in prior versions.
425 The fix restores 8.1 behavior for such cases.
426 </para>
427 </listitem>
429 <listitem>
430 <para>
431 Fix mis-expansion of rule queries when a sub-<literal>SELECT</> appears
432 in a function call in <literal>FROM</>, a multi-row <literal>VALUES</>
433 list, or a <literal>RETURNING</> list (Tom)
434 </para>
436 <para>
437 The usual symptom of this problem is an <quote>unrecognized node type</>
438 error.
439 </para>
440 </listitem>
442 <listitem>
443 <para>
444 Fix memory leak during rescan of a hashed aggregation plan (Neil)
445 </para>
446 </listitem>
448 <listitem>
449 <para>
450 Ensure an error is reported when a newly-defined PL/pgSQL trigger
451 function is invoked as a normal function (Tom)
452 </para>
453 </listitem>
455 <listitem>
456 <para>
457 Prevent possible collision of <structfield>relfilenode</> numbers
458 when moving a table to another tablespace with <command>ALTER SET
459 TABLESPACE</> (Heikki)
460 </para>
462 <para>
463 The command tried to re-use the existing filename, instead of
464 picking one that is known unused in the destination directory.
465 </para>
466 </listitem>
468 <listitem>
469 <para>
470 Fix incorrect tsearch2 headline generation when single query
471 item matches first word of text (Sushant Sinha)
472 </para>
473 </listitem>
475 <listitem>
476 <para>
477 Fix improper display of fractional seconds in interval values when
478 using a non-ISO datestyle in an <option>--enable-integer-datetimes</>
479 build (Ron Mayer)
480 </para>
481 </listitem>
483 <listitem>
484 <para>
485 Ensure <function>SPI_getvalue</> and <function>SPI_getbinval</>
486 behave correctly when the passed tuple and tuple descriptor have
487 different numbers of columns (Tom)
488 </para>
490 <para>
491 This situation is normal when a table has had columns added or removed,
492 but these two functions didn't handle it properly.
493 The only likely consequence is an incorrect error indication.
494 </para>
495 </listitem>
497 <listitem>
498 <para>
499 Fix <application>ecpg</>'s parsing of <command>CREATE ROLE</> (Michael)
500 </para>
501 </listitem>
503 <listitem>
504 <para>
505 Fix recent breakage of <literal>pg_ctl restart</> (Tom)
506 </para>
507 </listitem>
509 <listitem>
510 <para>
511 Ensure <filename>pg_control</> is opened in binary mode
512 (Itagaki Takahiro)
513 </para>
515 <para>
516 <application>pg_controldata</> and <application>pg_resetxlog</>
517 did this incorrectly, and so could fail on Windows.
518 </para>
519 </listitem>
521 <listitem>
522 <para>
523 Update time zone data files to <application>tzdata</> release 2008i (for
524 DST law changes in Argentina, Brazil, Mauritius, Syria)
525 </para>
526 </listitem>
528 </itemizedlist>
530 </sect2>
531 </sect1>
533 <sect1 id="release-8-2-10">
534 <title>Release 8.2.10</title>
536 <note>
537 <title>Release date</title>
538 <simpara>2008-09-22</simpara>
539 </note>
541 <para>
542 This release contains a variety of fixes from 8.2.9.
543 For information about new features in the 8.2 major release, see
544 <xref linkend="release-8-2">.
545 </para>
547 <sect2>
548 <title>Migration to Version 8.2.10</title>
550 <para>
551 A dump/restore is not required for those running 8.2.X.
552 However, if you are upgrading from a version earlier than 8.2.7,
553 see the release notes for 8.2.7.
554 </para>
556 </sect2>
558 <sect2>
559 <title>Changes</title>
561 <itemizedlist>
563 <listitem>
564 <para>
565 Fix bug in btree WAL recovery code (Heikki)
566 </para>
568 <para>
569 Recovery failed if the WAL ended partway through a page split operation.
570 </para>
571 </listitem>
573 <listitem>
574 <para>
575 Fix potential miscalculation of <structfield>datfrozenxid</> (Alvaro)
576 </para>
578 <para>
579 This error may explain some recent reports of failure to remove old
580 <structname>pg_clog</> data.
581 </para>
582 </listitem>
584 <listitem>
585 <para>
586 Widen local lock counters from 32 to 64 bits (Tom)
587 </para>
589 <para>
590 This responds to reports that the counters could overflow in
591 sufficiently long transactions, leading to unexpected <quote>lock is
592 already held</> errors.
593 </para>
594 </listitem>
596 <listitem>
597 <para>
598 Fix possible duplicate output of tuples during a GiST index scan (Teodor)
599 </para>
600 </listitem>
602 <listitem>
603 <para>
604 Fix missed permissions checks when a view contains a simple
605 <literal>UNION ALL</> construct (Heikki)
606 </para>
608 <para>
609 Permissions for the referenced tables were checked properly, but not
610 permissions for the view itself.
611 </para>
612 </listitem>
614 <listitem>
615 <para>
616 Add checks in executor startup to ensure that the tuples produced by an
617 <command>INSERT</> or <command>UPDATE</> will match the target table's
618 current rowtype (Tom)
619 </para>
621 <para>
622 <command>ALTER COLUMN TYPE</>, followed by re-use of a previously
623 cached plan, could produce this type of situation. The check protects
624 against data corruption and/or crashes that could ensue.
625 </para>
626 </listitem>
628 <listitem>
629 <para>
630 Fix possible repeated drops during <command>DROP OWNED</> (Tom)
631 </para>
633 <para>
634 This would typically result in strange errors such as <quote>cache
635 lookup failed for relation NNN</>.
636 </para>
637 </listitem>
639 <listitem>
640 <para>
641 Fix <literal>AT TIME ZONE</> to first try to interpret its timezone
642 argument as a timezone abbreviation, and only try it as a full timezone
643 name if that fails, rather than the other way around as formerly (Tom)
644 </para>
646 <para>
647 The timestamp input functions have always resolved ambiguous zone names
648 in this order. Making <literal>AT TIME ZONE</> do so as well improves
649 consistency, and fixes a compatibility bug introduced in 8.1:
650 in ambiguous cases we now behave the same as 8.0 and before did,
651 since in the older versions <literal>AT TIME ZONE</> accepted
652 <emphasis>only</> abbreviations.
653 </para>
654 </listitem>
656 <listitem>
657 <para>
658 Fix datetime input functions to correctly detect integer overflow when
659 running on a 64-bit platform (Tom)
660 </para>
661 </listitem>
663 <listitem>
664 <para>
665 Prevent integer overflows during units conversion when displaying a
666 configuration parameter that has units (Tom)
667 </para>
668 </listitem>
670 <listitem>
671 <para>
672 Improve performance of writing very long log messages to syslog (Tom)
673 </para>
674 </listitem>
676 <listitem>
677 <para>
678 Allow spaces in the suffix part of an LDAP URL in
679 <filename>pg_hba.conf</> (Tom)
680 </para>
681 </listitem>
683 <listitem>
684 <para>
685 Fix bug in backwards scanning of a cursor on a <literal>SELECT DISTINCT
686 ON</> query (Tom)
687 </para>
688 </listitem>
690 <listitem>
691 <para>
692 Fix planner bug with nested sub-select expressions (Tom)
693 </para>
695 <para>
696 If the outer sub-select has no direct dependency on the parent query,
697 but the inner one does, the outer value might not get recalculated
698 for new parent query rows.
699 </para>
700 </listitem>
702 <listitem>
703 <para>
704 Fix planner to estimate that <literal>GROUP BY</> expressions yielding
705 boolean results always result in two groups, regardless of the
706 expressions' contents (Tom)
707 </para>
709 <para>
710 This is very substantially more accurate than the regular <literal>GROUP
711 BY</> estimate for certain boolean tests like <replaceable>col</>
712 <literal>IS NULL</>.
713 </para>
714 </listitem>
716 <listitem>
717 <para>
718 Fix PL/PgSQL to not fail when a <literal>FOR</> loop's target variable
719 is a record containing composite-type fields (Tom)
720 </para>
721 </listitem>
723 <listitem>
724 <para>
725 Fix PL/Tcl to behave correctly with Tcl 8.5, and to be more careful
726 about the encoding of data sent to or from Tcl (Tom)
727 </para>
728 </listitem>
730 <listitem>
731 <para>
732 On Windows, work around a Microsoft bug by preventing
733 <application>libpq</> from trying to send more than 64kB per system call
734 (Magnus)
735 </para>
736 </listitem>
738 <listitem>
739 <para>
740 Improve <application>pg_dump</> and <application>pg_restore</>'s
741 error reporting after failure to send a SQL command (Tom)
742 </para>
743 </listitem>
745 <listitem>
746 <para>
747 Fix <application>pg_ctl</> to properly preserve postmaster
748 command-line arguments across a <literal>restart</> (Bruce)
749 </para>
750 </listitem>
752 <listitem>
753 <para>
754 Update time zone data files to <application>tzdata</> release 2008f (for
755 DST law changes in Argentina, Bahamas, Brazil, Mauritius, Morocco,
756 Pakistan, Palestine, and Paraguay)
757 </para>
758 </listitem>
760 </itemizedlist>
762 </sect2>
763 </sect1>
765 <sect1 id="release-8-2-9">
766 <title>Release 8.2.9</title>
768 <note>
769 <title>Release date</title>
770 <simpara>2008-06-12</simpara>
771 </note>
773 <para>
774 This release contains one serious and one minor bug fix over 8.2.8.
775 For information about new features in the 8.2 major release, see
776 <xref linkend="release-8-2">.
777 </para>
779 <sect2>
780 <title>Migration to Version 8.2.9</title>
782 <para>
783 A dump/restore is not required for those running 8.2.X.
784 However, if you are upgrading from a version earlier than 8.2.7,
785 see the release notes for 8.2.7.
786 </para>
788 </sect2>
790 <sect2>
791 <title>Changes</title>
793 <itemizedlist>
795 <listitem>
796 <para>
797 Make <function>pg_get_ruledef()</> parenthesize negative constants (Tom)
798 </para>
800 <para>
801 Before this fix, a negative constant in a view or rule might be dumped
802 as, say, <literal>-42::integer</>, which is subtly incorrect: it should
803 be <literal>(-42)::integer</> due to operator precedence rules.
804 Usually this would make little difference, but it could interact with
805 another recent patch to cause
806 <productname>PostgreSQL</> to reject what had been a valid
807 <command>SELECT DISTINCT</> view query. Since this could result in
808 <application>pg_dump</> output failing to reload, it is being treated
809 as a high-priority fix. The only released versions in which dump
810 output is actually incorrect are 8.3.1 and 8.2.7.
811 </para>
812 </listitem>
814 <listitem>
815 <para>
816 Make <command>ALTER AGGREGATE ... OWNER TO</> update
817 <structname>pg_shdepend</> (Tom)
818 </para>
820 <para>
821 This oversight could lead to problems if the aggregate was later
822 involved in a <command>DROP OWNED</> or <command>REASSIGN OWNED</>
823 operation.
824 </para>
825 </listitem>
827 </itemizedlist>
829 </sect2>
830 </sect1>
832 <sect1 id="release-8-2-8">
833 <title>Release 8.2.8</title>
835 <note>
836 <title>Release date</title>
837 <simpara>never released</simpara>
838 </note>
840 <para>
841 This release contains a variety of fixes from 8.2.7.
842 For information about new features in the 8.2 major release, see
843 <xref linkend="release-8-2">.
844 </para>
846 <sect2>
847 <title>Migration to Version 8.2.8</title>
849 <para>
850 A dump/restore is not required for those running 8.2.X.
851 However, if you are upgrading from a version earlier than 8.2.7,
852 see the release notes for 8.2.7.
853 </para>
855 </sect2>
857 <sect2>
858 <title>Changes</title>
860 <itemizedlist>
862 <listitem>
863 <para>
864 Fix <literal>ERRORDATA_STACK_SIZE exceeded</literal> crash that
865 occurred on Windows when using UTF-8 database encoding and a different
866 client encoding (Tom)
867 </para>
868 </listitem>
870 <listitem>
871 <para>
872 Fix <command>ALTER TABLE ADD COLUMN ... PRIMARY KEY</> so that the new
873 column is correctly checked to see if it's been initialized to all
874 non-nulls (Brendan Jurd)
875 </para>
877 <para>
878 Previous versions neglected to check this requirement at all.
879 </para>
880 </listitem>
882 <listitem>
883 <para>
884 Fix possible <command>CREATE TABLE</> failure when inheriting the
885 <quote>same</> constraint from multiple parent relations that
886 inherited that constraint from a common ancestor (Tom)
887 </para>
888 </listitem>
890 <listitem>
891 <para>
892 Fix <function>pg_get_ruledef()</> to show the alias, if any, attached
893 to the target table of an <command>UPDATE</> or <command>DELETE</>
894 (Tom)
895 </para>
896 </listitem>
898 <listitem>
899 <para>
900 Fix GIN bug that could result in a <literal>too many LWLocks
901 taken</literal> failure (Teodor)
902 </para>
903 </listitem>
905 <listitem>
906 <para>
907 Avoid possible crash when decompressing corrupted data
908 (Zdenek Kotala)
909 </para>
910 </listitem>
912 <listitem>
913 <para>
914 Repair two places where SIGTERM exit of a backend could leave corrupted
915 state in shared memory (Tom)
916 </para>
918 <para>
919 Neither case is very important if SIGTERM is used to shut down the
920 whole database cluster together, but there was a problem if someone
921 tried to SIGTERM individual backends.
922 </para>
923 </listitem>
925 <listitem>
926 <para>
927 Fix conversions between ISO-8859-5 and other encodings to handle
928 Cyrillic <quote>Yo</> characters (<literal>e</> and <literal>E</> with
929 two dots) (Sergey Burladyan)
930 </para>
931 </listitem>
933 <listitem>
934 <para>
935 Fix several datatype input functions, notably <function>array_in()</>,
936 that were allowing unused bytes in their results to contain
937 uninitialized, unpredictable values (Tom)
938 </para>
940 <para>
941 This could lead to failures in which two apparently identical literal
942 values were not seen as equal, resulting in the parser complaining
943 about unmatched <literal>ORDER BY</> and <literal>DISTINCT</>
944 expressions.
945 </para>
946 </listitem>
948 <listitem>
949 <para>
950 Fix a corner case in regular-expression substring matching
951 (<literal>substring(<replaceable>string</> from
952 <replaceable>pattern</>)</literal>) (Tom)
953 </para>
955 <para>
956 The problem occurs when there is a match to the pattern overall but
957 the user has specified a parenthesized subexpression and that
958 subexpression hasn't got a match. An example is
959 <literal>substring('foo' from 'foo(bar)?')</>.
960 This should return NULL, since <literal>(bar)</> isn't matched, but
961 it was mistakenly returning the whole-pattern match instead (ie,
962 <literal>foo</>).
963 </para>
964 </listitem>
966 <listitem>
967 <para>
968 Update time zone data files to <application>tzdata</> release 2008c (for
969 DST law changes in Morocco, Iraq, Choibalsan, Pakistan, Syria, Cuba, and
970 Argentina/San_Luis)
971 </para>
972 </listitem>
974 <listitem>
975 <para>
976 Fix incorrect result from <application>ecpg</>'s
977 <function>PGTYPEStimestamp_sub()</> function (Michael)
978 </para>
979 </listitem>
981 <listitem>
982 <para>
983 Fix broken GiST comparison function for <filename>contrib/tsearch2</>'s
984 <type>tsquery</> type (Teodor)
985 </para>
986 </listitem>
988 <listitem>
989 <para>
990 Fix possible crashes in <filename>contrib/cube</> functions (Tom)
991 </para>
992 </listitem>
994 <listitem>
995 <para>
996 Fix core dump in <filename>contrib/xml2</>'s
997 <function>xpath_table()</> function when the input query returns a
998 NULL value (Tom)
999 </para>
1000 </listitem>
1002 <listitem>
1003 <para>
1004 Fix <filename>contrib/xml2</>'s makefile to not override
1005 <literal>CFLAGS</> (Tom)
1006 </para>
1007 </listitem>
1009 <listitem>
1010 <para>
1011 Fix <literal>DatumGetBool</> macro to not fail with <application>gcc</>
1012 4.3 (Tom)
1013 </para>
1015 <para>
1016 This problem affects <quote>old style</> (V0) C functions that
1017 return boolean. The fix is already in 8.3, but the need to
1018 back-patch it was not realized at the time.
1019 </para>
1020 </listitem>
1022 </itemizedlist>
1024 </sect2>
1025 </sect1>
1027 <sect1 id="release-8-2-7">
1028 <title>Release 8.2.7</title>
1030 <note>
1031 <title>Release date</title>
1032 <simpara>2008-03-17</simpara>
1033 </note>
1035 <para>
1036 This release contains a variety of fixes from 8.2.6.
1037 For information about new features in the 8.2 major release, see
1038 <xref linkend="release-8-2">.
1039 </para>
1041 <sect2>
1042 <title>Migration to Version 8.2.7</title>
1044 <para>
1045 A dump/restore is not required for those running 8.2.X.
1046 However, you might need to <command>REINDEX</> indexes on textual
1047 columns after updating, if you are affected by the Windows locale
1048 issue described below.
1049 </para>
1051 </sect2>
1053 <sect2>
1054 <title>Changes</title>
1056 <itemizedlist>
1058 <listitem>
1059 <para>
1060 Fix character string comparison for Windows locales that consider
1061 different character combinations as equal (Tom)
1062 </para>
1064 <para>
1065 This fix applies only on Windows and only when using UTF-8
1066 database encoding. The same fix was made for all other cases
1067 over two years ago, but Windows with UTF-8 uses a separate code
1068 path that was not updated. If you are using a locale that
1069 considers some non-identical strings as equal, you may need to
1070 <command>REINDEX</> to fix existing indexes on textual columns.
1071 </para>
1072 </listitem>
1074 <listitem>
1075 <para>
1076 Repair potential deadlock between concurrent <command>VACUUM FULL</>
1077 operations on different system catalogs (Tom)
1078 </para>
1079 </listitem>
1081 <listitem>
1082 <para>
1083 Fix longstanding <command>LISTEN</>/<command>NOTIFY</>
1084 race condition (Tom)
1085 </para>
1087 <para>
1088 In rare cases a session that had just executed a
1089 <command>LISTEN</> might not get a notification, even though
1090 one would be expected because the concurrent transaction executing
1091 <command>NOTIFY</> was observed to commit later.
1092 </para>
1094 <para>
1095 A side effect of the fix is that a transaction that has executed
1096 a not-yet-committed <command>LISTEN</> command will not see any
1097 row in <structname>pg_listener</> for the <command>LISTEN</>,
1098 should it choose to look; formerly it would have. This behavior
1099 was never documented one way or the other, but it is possible that
1100 some applications depend on the old behavior.
1101 </para>
1102 </listitem>
1104 <listitem>
1105 <para>
1106 Disallow <command>LISTEN</> and <command>UNLISTEN</> within a
1107 prepared transaction (Tom)
1108 </para>
1110 <para>
1111 This was formerly allowed but trying to do it had various unpleasant
1112 consequences, notably that the originating backend could not exit
1113 as long as an <command>UNLISTEN</> remained uncommitted.
1114 </para>
1115 </listitem>
1117 <listitem>
1118 <para>
1119 Disallow dropping a temporary table within a
1120 prepared transaction (Heikki)
1121 </para>
1123 <para>
1124 This was correctly disallowed by 8.1, but the check was inadvertently
1125 broken in 8.2.
1126 </para>
1127 </listitem>
1129 <listitem>
1130 <para>
1131 Fix rare crash when an error occurs during a query using a hash index
1132 (Heikki)
1133 </para>
1134 </listitem>
1136 <listitem>
1137 <para>
1138 Fix memory leaks in certain usages of set-returning functions (Neil)
1139 </para>
1140 </listitem>
1142 <listitem>
1143 <para>
1144 Fix input of datetime values for February 29 in years BC (Tom)
1145 </para>
1147 <para>
1148 The former coding was mistaken about which years were leap years.
1149 </para>
1150 </listitem>
1152 <listitem>
1153 <para>
1154 Fix <quote>unrecognized node type</> error in some variants of
1155 <command>ALTER OWNER</> (Tom)
1156 </para>
1157 </listitem>
1159 <listitem>
1160 <para>
1161 Ensure <structname>pg_stat_activity</>.<structfield>waiting</> flag
1162 is cleared when a lock wait is aborted (Tom)
1163 </para>
1164 </listitem>
1166 <listitem>
1167 <para>
1168 Fix handling of process permissions on Windows Vista (Dave, Magnus)
1169 </para>
1171 <para>
1172 In particular, this fix allows starting the server as the Administrator
1173 user.
1174 </para>
1175 </listitem>
1177 <listitem>
1178 <para>
1179 Update time zone data files to <application>tzdata</> release 2008a
1180 (in particular, recent Chile changes); adjust timezone abbreviation
1181 <literal>VET</> (Venezuela) to mean UTC-4:30, not UTC-4:00 (Tom)
1182 </para>
1183 </listitem>
1185 <listitem>
1186 <para>
1187 Fix <application>pg_ctl</> to correctly extract the postmaster's port
1188 number from command-line options (Itagaki Takahiro, Tom)
1189 </para>
1191 <para>
1192 Previously, <literal>pg_ctl start -w</> could try to contact the
1193 postmaster on the wrong port, leading to bogus reports of startup
1194 failure.
1195 </para>
1196 </listitem>
1198 <listitem>
1199 <para>
1200 Use <option>-fwrapv</> to defend against possible misoptimization
1201 in recent <application>gcc</> versions (Tom)
1202 </para>
1204 <para>
1205 This is known to be necessary when building <productname>PostgreSQL</>
1206 with <application>gcc</> 4.3 or later.
1207 </para>
1208 </listitem>
1211 <listitem>
1212 <para>
1213 Correctly enforce <varname>statement_timeout</> values longer
1214 than <literal>INT_MAX</> microseconds (about 35 minutes) (Tom)
1215 </para>
1217 <para>
1218 This bug affects only builds with <option>--enable-integer-datetimes</>.
1219 </para>
1220 </listitem>
1222 <listitem>
1223 <para>
1224 Fix <quote>unexpected PARAM_SUBLINK ID</> planner error when
1225 constant-folding simplifies a sub-select (Tom)
1226 </para>
1227 </listitem>
1229 <listitem>
1230 <para>
1231 Fix logical errors in constraint-exclusion handling of <literal>IS
1232 NULL</> and <literal>NOT</> expressions (Tom)
1233 </para>
1235 <para>
1236 The planner would sometimes exclude partitions that should not
1237 have been excluded because of the possibility of NULL results.
1238 </para>
1239 </listitem>
1241 <listitem>
1242 <para>
1243 Fix another cause of <quote>failed to build any N-way joins</>
1244 planner errors (Tom)
1245 </para>
1247 <para>
1248 This could happen in cases where a clauseless join needed to be
1249 forced before a join clause could be exploited.
1250 </para>
1251 </listitem>
1253 <listitem>
1254 <para>
1255 Fix incorrect constant propagation in outer-join planning (Tom)
1256 </para>
1258 <para>
1259 The planner could sometimes incorrectly conclude that a variable
1260 could be constrained to be equal to a constant, leading
1261 to wrong query results.
1262 </para>
1263 </listitem>
1265 <listitem>
1266 <para>
1267 Fix display of constant expressions in <literal>ORDER BY</>
1268 and <literal>GROUP BY</> (Tom)
1269 </para>
1271 <para>
1272 An explictly casted constant would be shown incorrectly. This could
1273 for example lead to corruption of a view definition during
1274 dump and reload.
1275 </para>
1276 </listitem>
1278 <listitem>
1279 <para>
1280 Fix <application>libpq</> to handle NOTICE messages correctly
1281 during COPY OUT (Tom)
1282 </para>
1284 <para>
1285 This failure has only been observed to occur when a user-defined
1286 datatype's output routine issues a NOTICE, but there is no
1287 guarantee it couldn't happen due to other causes.
1288 </para>
1289 </listitem>
1291 </itemizedlist>
1293 </sect2>
1294 </sect1>
1296 <sect1 id="release-8-2-6">
1297 <title>Release 8.2.6</title>
1299 <note>
1300 <title>Release date</title>
1301 <simpara>2008-01-07</simpara>
1302 </note>
1304 <para>
1305 This release contains a variety of fixes from 8.2.5,
1306 including fixes for significant security issues.
1307 For information about new features in the 8.2 major release, see
1308 <xref linkend="release-8-2">.
1309 </para>
1311 <sect2>
1312 <title>Migration to Version 8.2.6</title>
1314 <para>
1315 A dump/restore is not required for those running 8.2.X.
1316 </para>
1318 </sect2>
1320 <sect2>
1321 <title>Changes</title>
1323 <itemizedlist>
1325 <listitem>
1326 <para>
1327 Prevent functions in indexes from executing with the privileges of
1328 the user running <command>VACUUM</>, <command>ANALYZE</>, etc (Tom)
1329 </para>
1331 <para>
1332 Functions used in index expressions and partial-index
1333 predicates are evaluated whenever a new table entry is made. It has
1334 long been understood that this poses a risk of trojan-horse code
1335 execution if one modifies a table owned by an untrustworthy user.
1336 (Note that triggers, defaults, check constraints, etc. pose the
1337 same type of risk.) But functions in indexes pose extra danger
1338 because they will be executed by routine maintenance operations
1339 such as <command>VACUUM FULL</>, which are commonly performed
1340 automatically under a superuser account. For example, a nefarious user
1341 can execute code with superuser privileges by setting up a
1342 trojan-horse index definition and waiting for the next routine vacuum.
1343 The fix arranges for standard maintenance operations
1344 (including <command>VACUUM</>, <command>ANALYZE</>, <command>REINDEX</>,
1345 and <command>CLUSTER</>) to execute as the table owner rather than
1346 the calling user, using the same privilege-switching mechanism already
1347 used for <literal>SECURITY DEFINER</> functions. To prevent bypassing
1348 this security measure, execution of <command>SET SESSION
1349 AUTHORIZATION</> and <command>SET ROLE</> is now forbidden within a
1350 <literal>SECURITY DEFINER</> context. (CVE-2007-6600)
1351 </para>
1352 </listitem>
1354 <listitem>
1355 <para>
1356 Repair assorted bugs in the regular-expression package (Tom, Will Drewry)
1357 </para>
1359 <para>
1360 Suitably crafted regular-expression patterns could cause crashes,
1361 infinite or near-infinite looping, and/or massive memory consumption,
1362 all of which pose denial-of-service hazards for applications that
1363 accept regex search patterns from untrustworthy sources.
1364 (CVE-2007-4769, CVE-2007-4772, CVE-2007-6067)
1365 </para>
1366 </listitem>
1368 <listitem>
1369 <para>
1370 Require non-superusers who use <filename>/contrib/dblink</> to use only
1371 password authentication, as a security measure (Joe)
1372 </para>
1374 <para>
1375 The fix that appeared for this in 8.2.5 was incomplete, as it plugged
1376 the hole for only some <filename>dblink</> functions. (CVE-2007-6601,
1377 CVE-2007-3278)
1378 </para>
1379 </listitem>
1381 <listitem>
1382 <para>
1383 Fix bugs in WAL replay for GIN indexes (Teodor)
1384 </para>
1385 </listitem>
1387 <listitem>
1388 <para>
1389 Fix GIN index build to work properly when
1390 <varname>maintenance_work_mem</> is 4GB or more (Tom)
1391 </para>
1392 </listitem>
1394 <listitem>
1395 <para>
1396 Update time zone data files to <application>tzdata</> release 2007k
1397 (in particular, recent Argentina changes) (Tom)
1398 </para>
1399 </listitem>
1401 <listitem>
1402 <para>
1403 Improve planner's handling of LIKE/regex estimation in non-C locales
1404 (Tom)
1405 </para>
1406 </listitem>
1408 <listitem>
1409 <para>
1410 Fix planning-speed problem for deep outer-join nests, as well as
1411 possible poor choice of join order (Tom)
1412 </para>
1413 </listitem>
1415 <listitem>
1416 <para>
1417 Fix planner failure in some cases of <literal>WHERE false AND var IN
1418 (SELECT ...)</> (Tom)
1419 </para>
1420 </listitem>
1422 <listitem>
1423 <para>
1424 Make <command>CREATE TABLE ... SERIAL</> and
1425 <command>ALTER SEQUENCE ... OWNED BY</> not change the
1426 <function>currval()</> state of the sequence (Tom)
1427 </para>
1428 </listitem>
1430 <listitem>
1431 <para>
1432 Preserve the tablespace and storage parameters of indexes that are
1433 rebuilt by <command>ALTER TABLE ... ALTER COLUMN TYPE</> (Tom)
1434 </para>
1435 </listitem>
1437 <listitem>
1438 <para>
1439 Make archive recovery always start a new WAL timeline, rather than only
1440 when a recovery stop time was used (Simon)
1441 </para>
1443 <para>
1444 This avoids a corner-case risk of trying to overwrite an existing
1445 archived copy of the last WAL segment, and seems simpler and cleaner
1446 than the original definition.
1447 </para>
1448 </listitem>
1450 <listitem>
1451 <para>
1452 Make <command>VACUUM</> not use all of <varname>maintenance_work_mem</>
1453 when the table is too small for it to be useful (Alvaro)
1454 </para>
1455 </listitem>
1457 <listitem>
1458 <para>
1459 Fix potential crash in <function>translate()</> when using a multibyte
1460 database encoding (Tom)
1461 </para>
1462 </listitem>
1464 <listitem>
1465 <para>
1466 Make <function>corr()</> return the correct result for negative
1467 correlation values (Neil)
1468 </para>
1469 </listitem>
1471 <listitem>
1472 <para>
1473 Fix overflow in <literal>extract(epoch from interval)</> for intervals
1474 exceeding 68 years (Tom)
1475 </para>
1476 </listitem>
1478 <listitem>
1479 <para>
1480 Fix PL/Perl to not fail when a UTF-8 regular expression is used
1481 in a trusted function (Andrew)
1482 </para>
1483 </listitem>
1485 <listitem>
1486 <para>
1487 Fix PL/Perl to cope when platform's Perl defines type <literal>bool</>
1488 as <literal>int</> rather than <literal>char</> (Tom)
1489 </para>
1491 <para>
1492 While this could theoretically happen anywhere, no standard build of
1493 Perl did things this way ... until <productname>Mac OS X</> 10.5.
1494 </para>
1495 </listitem>
1497 <listitem>
1498 <para>
1499 Fix PL/Python to work correctly with Python 2.5 on 64-bit machines
1500 (Marko Kreen)
1501 </para>
1502 </listitem>
1504 <listitem>
1505 <para>
1506 Fix PL/Python to not crash on long exception messages (Alvaro)
1507 </para>
1508 </listitem>
1510 <listitem>
1511 <para>
1512 Fix <application>pg_dump</> to correctly handle inheritance child tables
1513 that have default expressions different from their parent's (Tom)
1514 </para>
1515 </listitem>
1517 <listitem>
1518 <para>
1519 Fix <application>libpq</> crash when <varname>PGPASSFILE</> refers
1520 to a file that is not a plain file (Martin Pitt)
1521 </para>
1522 </listitem>
1524 <listitem>
1525 <para>
1526 <application>ecpg</> parser fixes (Michael)
1527 </para>
1528 </listitem>
1530 <listitem>
1531 <para>
1532 Make <filename>contrib/pgcrypto</> defend against
1533 <application>OpenSSL</> libraries that fail on keys longer than 128
1534 bits; which is the case at least on some Solaris versions (Marko Kreen)
1535 </para>
1536 </listitem>
1538 <listitem>
1539 <para>
1540 Make <filename>contrib/tablefunc</>'s <function>crosstab()</> handle
1541 NULL rowid as a category in its own right, rather than crashing (Joe)
1542 </para>
1543 </listitem>
1545 <listitem>
1546 <para>
1547 Fix <type>tsvector</> and <type>tsquery</> output routines to
1548 escape backslashes correctly (Teodor, Bruce)
1549 </para>
1550 </listitem>
1552 <listitem>
1553 <para>
1554 Fix crash of <function>to_tsvector()</> on huge input strings (Teodor)
1555 </para>
1556 </listitem>
1558 <listitem>
1559 <para>
1560 Require a specific version of <productname>Autoconf</> to be used
1561 when re-generating the <command>configure</> script (Peter)
1562 </para>
1564 <para>
1565 This affects developers and packagers only. The change was made
1566 to prevent accidental use of untested combinations of
1567 <productname>Autoconf</> and <productname>PostgreSQL</> versions.
1568 You can remove the version check if you really want to use a
1569 different <productname>Autoconf</> version, but it's
1570 your responsibility whether the result works or not.
1571 </para>
1572 </listitem>
1574 <listitem>
1575 <para>
1576 Update <function>gettimeofday</> configuration check so that
1577 <productname>PostgreSQL</> can be built on newer versions of
1578 <productname>MinGW</> (Magnus)
1579 </para>
1580 </listitem>
1582 </itemizedlist>
1584 </sect2>
1585 </sect1>
1587 <sect1 id="release-8-2-5">
1588 <title>Release 8.2.5</title>
1590 <note>
1591 <title>Release date</title>
1592 <simpara>2007-09-17</simpara>
1593 </note>
1595 <para>
1596 This release contains a variety of fixes from 8.2.4.
1597 For information about new features in the 8.2 major release, see
1598 <xref linkend="release-8-2">.
1599 </para>
1601 <sect2>
1602 <title>Migration to Version 8.2.5</title>
1604 <para>
1605 A dump/restore is not required for those running 8.2.X.
1606 </para>
1608 </sect2>
1610 <sect2>
1611 <title>Changes</title>
1613 <itemizedlist>
1615 <listitem>
1616 <para>
1617 Prevent index corruption when a transaction inserts rows and
1618 then aborts close to the end of a concurrent <command>VACUUM</>
1619 on the same table (Tom)
1620 </para>
1621 </listitem>
1623 <listitem>
1624 <para>
1625 Fix <literal>ALTER DOMAIN ADD CONSTRAINT</> for cases involving
1626 domains over domains (Tom)
1627 </para>
1628 </listitem>
1630 <listitem>
1631 <para>
1632 Make <command>CREATE DOMAIN ... DEFAULT NULL</> work properly (Tom)
1633 </para>
1634 </listitem>
1636 <listitem>
1637 <para>
1638 Fix some planner problems with outer joins, notably poor
1639 size estimation for <literal>t1 LEFT JOIN t2 WHERE t2.col IS NULL</>
1640 (Tom)
1641 </para>
1642 </listitem>
1644 <listitem>
1645 <para>
1646 Allow the <type>interval</> data type to accept input consisting only of
1647 milliseconds or microseconds (Neil)
1648 </para>
1649 </listitem>
1651 <listitem>
1652 <para>
1653 Allow timezone name to appear before the year in <type>timestamp</> input (Tom)
1654 </para>
1655 </listitem>
1657 <listitem>
1658 <para>
1659 Fixes for <acronym>GIN</> indexes used by <filename>/contrib/tsearch2</> (Teodor)
1660 </para>
1661 </listitem>
1663 <listitem>
1664 <para>
1665 Speed up rtree index insertion (Teodor)
1666 </para>
1667 </listitem>
1669 <listitem>
1670 <para>
1671 Fix excessive logging of <acronym>SSL</> error messages (Tom)
1672 </para>
1673 </listitem>
1675 <listitem>
1676 <para>
1677 Fix logging so that log messages are never interleaved when using
1678 the syslogger process (Andrew)
1679 </para>
1680 </listitem>
1682 <listitem>
1683 <para>
1684 Fix crash when <varname>log_min_error_statement</> logging runs out
1685 of memory (Tom)
1686 </para>
1687 </listitem>
1689 <listitem>
1690 <para>
1691 Fix incorrect handling of some foreign-key corner cases (Tom)
1692 </para>
1693 </listitem>
1695 <listitem>
1696 <para>
1697 Fix <function>stddev_pop(numeric)</> and <function>var_pop(numeric)</> (Tom)
1698 </para>
1699 </listitem>
1701 <listitem>
1702 <para>
1703 Prevent <command>REINDEX</> and <command>CLUSTER</> from failing
1704 due to attempting to process temporary tables of other sessions (Alvaro)
1705 </para>
1706 </listitem>
1708 <listitem>
1709 <para>
1710 Update the time zone database rules, particularly New Zealand's upcoming changes (Tom)
1711 </para>
1712 </listitem>
1714 <listitem>
1715 <para>
1716 Windows socket and semaphore improvements (Magnus)
1717 </para>
1718 </listitem>
1720 <listitem>
1721 <para>
1722 Make <command>pg_ctl -w</> work properly in Windows service mode (Dave Page)
1723 </para>
1724 </listitem>
1726 <listitem>
1727 <para>
1728 Fix memory allocation bug when using <application>MIT Kerberos</> on Windows (Magnus)
1729 </para>
1730 </listitem>
1732 <listitem>
1733 <para>
1734 Suppress timezone name (<literal>%Z</>) in log timestamps on Windows
1735 because of possible encoding mismatches (Tom)
1736 </para>
1737 </listitem>
1739 <listitem>
1740 <para>
1741 Require non-superusers who use <filename>/contrib/dblink</> to use only
1742 password authentication, as a security measure (Joe)
1743 </para>
1744 </listitem>
1746 <listitem>
1747 <para>
1748 Restrict <filename>/contrib/pgstattuple</> functions to superusers, for security reasons (Tom)
1749 </para>
1750 </listitem>
1752 <listitem>
1753 <para>
1754 Do not let <filename>/contrib/intarray</> try to make its GIN opclass
1755 the default (this caused problems at dump/restore) (Tom)
1756 </para>
1757 </listitem>
1759 </itemizedlist>
1761 </sect2>
1762 </sect1>
1764 <sect1 id="release-8-2-4">
1765 <title>Release 8.2.4</title>
1767 <note>
1768 <title>Release date</title>
1769 <simpara>2007-04-23</simpara>
1770 </note>
1772 <para>
1773 This release contains a variety of fixes from 8.2.3,
1774 including a security fix.
1775 For information about new features in the 8.2 major release, see
1776 <xref linkend="release-8-2">.
1777 </para>
1779 <sect2>
1780 <title>Migration to Version 8.2.4</title>
1782 <para>
1783 A dump/restore is not required for those running 8.2.X.
1784 </para>
1786 </sect2>
1788 <sect2>
1789 <title>Changes</title>
1791 <itemizedlist>
1793 <listitem>
1794 <para>
1795 Support explicit placement of the temporary-table schema within
1796 <varname>search_path</>, and disable searching it for functions
1797 and operators (Tom)
1798 </para>
1800 <para>
1801 This is needed to allow a security-definer function to set a
1802 truly secure value of <varname>search_path</>. Without it,
1803 an unprivileged SQL user can use temporary objects to execute code
1804 with the privileges of the security-definer function (CVE-2007-2138).
1805 See <command>CREATE FUNCTION</> for more information.
1806 </para>
1807 </listitem>
1809 <listitem>
1810 <para>
1811 Fix <varname>shared_preload_libraries</> for Windows
1812 by forcing reload in each backend (Korry Douglas)
1813 </para>
1814 </listitem>
1816 <listitem>
1817 <para>
1818 Fix <function>to_char()</> so it properly upper/lower cases localized day or month
1819 names (Pavel Stehule)
1820 </para>
1821 </listitem>
1823 <listitem>
1824 <para>
1825 <filename>/contrib/tsearch2</> crash fixes (Teodor)
1826 </para>
1827 </listitem>
1829 <listitem>
1830 <para>
1831 Require <command>COMMIT PREPARED</> to be executed in the same
1832 database as the transaction was prepared in (Heikki)
1833 </para>
1834 </listitem>
1836 <listitem>
1837 <para>
1838 Allow <command>pg_dump</> to do binary backups larger than two gigabytes
1839 on Windows (Magnus)
1840 </para>
1841 </listitem>
1843 <listitem>
1844 <para>
1845 New traditional (Taiwan) Chinese <acronym>FAQ</> (Zhou Daojing)
1846 </para>
1847 </listitem>
1849 <listitem>
1850 <para>
1851 Prevent the statistics collector from writing to disk too frequently (Tom)
1852 </para>
1853 </listitem>
1855 <listitem>
1856 <para>
1857 Fix potential-data-corruption bug in how <command>VACUUM FULL</> handles
1858 <command>UPDATE</> chains (Tom, Pavan Deolasee)
1859 </para>
1860 </listitem>
1862 <listitem>
1863 <para>
1864 Fix bug in domains that use array types (Tom)
1865 </para>
1866 </listitem>
1868 <listitem>
1869 <para>
1870 Fix <command>pg_dump</> so it can dump a serial column's sequence
1871 using <option>-t</> when not also dumping the owning table
1872 (Tom)
1873 </para>
1874 </listitem>
1876 <listitem>
1877 <para>
1878 Planner fixes, including improving outer join and bitmap scan
1879 selection logic (Tom)
1880 </para>
1881 </listitem>
1883 <listitem>
1884 <para>
1885 Fix possible wrong answers or crash when a PL/pgSQL function tries
1886 to <literal>RETURN</> from within an <literal>EXCEPTION</> block
1887 (Tom)
1888 </para>
1889 </listitem>
1891 <listitem>
1892 <para>
1893 Fix PANIC during enlargement of a hash index (Tom)
1894 </para>
1895 </listitem>
1897 <listitem>
1898 <para>
1899 Fix POSIX-style timezone specs to follow new USA DST rules (Tom)
1900 </para>
1901 </listitem>
1903 </itemizedlist>
1905 </sect2>
1906 </sect1>
1908 <sect1 id="release-8-2-3">
1909 <title>Release 8.2.3</title>
1911 <note>
1912 <title>Release date</title>
1913 <simpara>2007-02-07</simpara>
1914 </note>
1916 <para>
1917 This release contains two fixes from 8.2.2.
1918 For information about new features in the 8.2 major release, see
1919 <xref linkend="release-8-2">.
1920 </para>
1922 <sect2>
1923 <title>Migration to Version 8.2.3</title>
1925 <para>
1926 A dump/restore is not required for those running 8.2.X.
1927 </para>
1929 </sect2>
1931 <sect2>
1932 <title>Changes</title>
1934 <itemizedlist>
1936 <listitem>
1937 <para>
1938 Remove overly-restrictive check for type length in constraints and
1939 functional indexes(Tom)
1940 </para>
1941 </listitem>
1943 <listitem>
1944 <para>
1945 Fix optimization so MIN/MAX in subqueries can again use indexes (Tom)
1946 </para>
1947 </listitem>
1949 </itemizedlist>
1951 </sect2>
1952 </sect1>
1954 <sect1 id="release-8-2-2">
1955 <title>Release 8.2.2</title>
1957 <note>
1958 <title>Release date</title>
1959 <simpara>2007-02-05</simpara>
1960 </note>
1962 <para>
1963 This release contains a variety of fixes from 8.2.1, including
1964 a security fix.
1965 For information about new features in the 8.2 major release, see
1966 <xref linkend="release-8-2">.
1967 </para>
1969 <sect2>
1970 <title>Migration to Version 8.2.2</title>
1972 <para>
1973 A dump/restore is not required for those running 8.2.X.
1974 </para>
1976 </sect2>
1978 <sect2>
1979 <title>Changes</title>
1981 <itemizedlist>
1983 <listitem>
1984 <para>
1985 Remove security vulnerabilities that allowed connected users
1986 to read backend memory (Tom)
1987 </para>
1989 <para>
1990 The vulnerabilities involve suppressing the normal check that a SQL
1991 function returns the data type it's declared to, and changing the
1992 data type of a table column (CVE-2007-0555, CVE-2007-0556). These
1993 errors can easily be exploited to cause a backend crash, and in
1994 principle might be used to read database content that the user
1995 should not be able to access.
1996 </para>
1997 </listitem>
1999 <listitem>
2000 <para>
2001 Fix not-so-rare-anymore bug wherein btree index page splits could fail
2002 due to choosing an infeasible split point (Heikki Linnakangas)
2003 </para>
2004 </listitem>
2006 <listitem>
2007 <para>
2008 Fix Borland C compile scripts (L Bayuk)
2009 </para>
2010 </listitem>
2012 <listitem>
2013 <para>
2014 Properly handle <function>to_char('CC')</> for years ending in
2015 <literal>00</> (Tom)
2016 </para>
2018 <para>
2019 Year 2000 is in the twentieth century, not the twenty-first.
2020 </para>
2021 </listitem>
2023 <listitem>
2024 <para>
2025 <filename>/contrib/tsearch2</> localization improvements (Tatsuo, Teodor)
2026 </para>
2027 </listitem>
2029 <listitem>
2030 <para>
2031 Fix incorrect permission check in
2032 <literal>information_schema.key_column_usage</> view (Tom)
2033 </para>
2035 <para>
2036 The symptom is <quote>relation with OID nnnnn does not exist</> errors.
2037 To get this fix without using <command>initdb</>, use <command>CREATE OR
2038 REPLACE VIEW</> to install the corrected definition found in
2039 <filename>share/information_schema.sql</>. Note you will need to do
2040 this in each database.
2041 </para>
2042 </listitem>
2044 <listitem>
2045 <para>
2046 Improve <command>VACUUM</> performance for databases with many tables (Tom)
2047 </para>
2048 </listitem>
2050 <listitem>
2051 <para>
2052 Fix for rare Assert() crash triggered by <literal>UNION</> (Tom)
2053 </para>
2054 </listitem>
2056 <listitem>
2057 <para>
2058 Fix potentially incorrect results from index searches using
2059 <literal>ROW</> inequality conditions (Tom)
2060 </para>
2061 </listitem>
2063 <listitem>
2064 <para>
2065 Tighten security of multi-byte character processing for UTF8 sequences
2066 over three bytes long (Tom)
2067 </para>
2068 </listitem>
2070 <listitem>
2071 <para>
2072 Fix bogus <quote>permission denied</> failures occurring on Windows
2073 due to attempts to fsync already-deleted files (Magnus, Tom)
2074 </para>
2075 </listitem>
2077 <listitem>
2078 <para>
2079 Fix bug that could cause the statistics collector
2080 to hang on Windows (Magnus)
2081 </para>
2083 <para>
2084 This would in turn lead to autovacuum not working.
2085 </para>
2086 </listitem>
2088 <listitem>
2089 <para>
2090 Fix possible crashes when an already-in-use PL/pgSQL function is
2091 updated (Tom)
2092 </para>
2093 </listitem>
2095 <listitem>
2096 <para>
2097 Improve PL/pgSQL handling of domain types (Sergiy Vyshnevetskiy, Tom)
2098 </para>
2099 </listitem>
2101 <listitem>
2102 <para>
2103 Fix possible errors in processing PL/pgSQL exception blocks (Tom)
2104 </para>
2105 </listitem>
2107 </itemizedlist>
2109 </sect2>
2110 </sect1>
2112 <sect1 id="release-8-2-1">
2113 <title>Release 8.2.1</title>
2115 <note>
2116 <title>Release date</title>
2117 <simpara>2007-01-08</simpara>
2118 </note>
2120 <para>
2121 This release contains a variety of fixes from 8.2.
2122 For information about new features in the 8.2 major release, see
2123 <xref linkend="release-8-2">.
2124 </para>
2126 <sect2>
2127 <title>Migration to Version 8.2.1</title>
2129 <para>
2130 A dump/restore is not required for those running 8.2.
2131 </para>
2133 </sect2>
2135 <sect2>
2136 <title>Changes</title>
2138 <itemizedlist>
2140 <listitem>
2141 <para>
2142 Fix crash with <literal>SELECT</> ... <literal>LIMIT ALL</> (also
2143 <literal>LIMIT NULL</>) (Tom)
2144 </para>
2145 </listitem>
2147 <listitem>
2148 <para>
2149 <filename>Several /contrib/tsearch2</> fixes (Teodor)
2150 </para>
2151 </listitem>
2153 <listitem>
2154 <para>
2155 On Windows, make log messages coming from the operating system use
2156 <acronym>ASCII</> encoding (Hiroshi Saito)
2157 </para>
2159 <para>
2160 This fixes a conversion problem when there is a mismatch between
2161 the encoding of the operating system and database server.
2162 </para>
2163 </listitem>
2165 <listitem>
2166 <para>
2167 Fix Windows linking of <application>pg_dump</> using
2168 <filename>win32.mak</>
2169 (Hiroshi Saito)
2170 </para>
2171 </listitem>
2173 <listitem>
2174 <para>
2175 Fix planner mistakes for outer join queries (Tom)
2176 </para>
2177 </listitem>
2179 <listitem>
2180 <para>
2181 Fix several problems in queries involving sub-SELECTs (Tom)
2182 </para>
2183 </listitem>
2185 <listitem>
2186 <para>
2187 Fix potential crash in SPI during subtransaction abort (Tom)
2188 </para>
2190 <para>
2191 This affects all PL functions since they all use SPI.
2192 </para>
2193 </listitem>
2195 <listitem>
2196 <para>
2197 Improve build speed of <acronym>PDF</> documentation (Peter)
2198 </para>
2199 </listitem>
2201 <listitem>
2202 <para>
2203 Re-add <acronym>JST</> (Japan) timezone abbreviation (Tom)
2204 </para>
2205 </listitem>
2207 <listitem>
2208 <para>
2209 Improve optimization decisions related to index scans (Tom)
2210 </para>
2211 </listitem>
2213 <listitem>
2214 <para>
2215 Have <application>psql</> print multi-byte combining characters as
2216 before, rather than output as <literal>\u</> (Tom)
2217 </para>
2218 </listitem>
2220 <listitem>
2221 <para>
2222 Improve index usage of regular expressions that use parentheses (Tom)
2223 </para>
2225 <para>
2226 This improves <application>psql</> <literal>\d</> performance also.
2227 </para>
2228 </listitem>
2230 <listitem>
2231 <para>
2232 Make <application>pg_dumpall</> assume that databases have public
2233 <literal>CONNECT</> privilege, when dumping from a pre-8.2 server (Tom)
2234 </para>
2236 <para>
2237 This preserves the previous behavior that anyone can connect to a
2238 database if allowed by <filename>pg_hba.conf</>.
2239 </para>
2240 </listitem>
2242 </itemizedlist>
2244 </sect2>
2245 </sect1>
2247 <sect1 id="release-8-2">
2248 <title>Release 8.2</title>
2250 <note>
2251 <title>Release date</title>
2252 <simpara>2006-12-05</simpara>
2253 </note>
2255 <sect2>
2256 <title>Overview</title>
2258 <para>
2259 This release adds many functionality and performance improvements that
2260 were requested by users, including:
2262 <itemizedlist>
2264 <listitem>
2265 <para>
2266 Query language enhancements including <command>INSERT/UPDATE/DELETE
2267 RETURNING</command>, multirow <literal>VALUES</literal> lists, and
2268 optional target-table alias in
2269 <command>UPDATE</>/<command>DELETE</command>
2270 </para>
2271 </listitem>
2273 <listitem>
2274 <para>
2275 Index creation without blocking concurrent
2276 <command>INSERT</>/<command>UPDATE</>/<command>DELETE</>
2277 operations
2278 </para>
2279 </listitem>
2281 <listitem>
2282 <para>
2283 Many query optimization improvements, including support for
2284 reordering outer joins
2285 </para>
2286 </listitem>
2288 <listitem>
2289 <para>
2290 Improved sorting performance with lower memory usage
2291 </para>
2292 </listitem>
2294 <listitem>
2295 <para>
2296 More efficient locking with better concurrency
2297 </para>
2298 </listitem>
2300 <listitem>
2301 <para>
2302 More efficient vacuuming
2303 </para>
2304 </listitem>
2306 <listitem>
2307 <para>
2308 Easier administration of warm standby servers
2309 </para>
2310 </listitem>
2312 <listitem>
2313 <para>
2314 New <literal>FILLFACTOR</literal> support for tables and indexes
2315 </para>
2316 </listitem>
2318 <listitem>
2319 <para>
2320 Monitoring, logging, and performance tuning additions
2321 </para>
2322 </listitem>
2324 <listitem>
2325 <para>
2326 More control over creating and dropping objects
2327 </para>
2328 </listitem>
2330 <listitem>
2331 <para>
2332 Table inheritance relationships can be defined
2333 for and removed from pre-existing tables
2334 </para>
2335 </listitem>
2337 <listitem>
2338 <para>
2339 <command>COPY TO</command> can copy the output of an arbitrary
2340 <command>SELECT</command> statement
2341 </para>
2342 </listitem>
2344 <listitem>
2345 <para>
2346 Array improvements, including nulls in arrays
2347 </para>
2348 </listitem>
2350 <listitem>
2351 <para>
2352 Aggregate-function improvements, including multiple-input
2353 aggregates and SQL:2003 statistical functions
2354 </para>
2355 </listitem>
2357 <listitem>
2358 <para>
2359 Many <filename>contrib/</filename> improvements
2360 </para>
2361 </listitem>
2363 </itemizedlist>
2365 </para>
2367 </sect2>
2369 <sect2>
2370 <title>Migration to Version 8.2</title>
2372 <para>
2373 A dump/restore using <application>pg_dump</application> is
2374 required for those wishing to migrate data from any previous
2375 release.
2376 </para>
2378 <para>
2379 Observe the following incompatibilities:
2380 </para>
2382 <itemizedlist>
2384 <listitem>
2385 <para>
2386 Set <link
2387 linkend="guc-escape-string-warning"><varname>escape_string_warning</></link>
2388 to <literal>on</> by default (Bruce)
2389 </para>
2391 <para>
2392 This issues a warning if backslash escapes are used in
2393 <link linkend="sql-syntax-strings">non-escape (non-<literal>E''</>)
2394 strings</link>.
2395 </para>
2396 </listitem>
2398 <listitem>
2399 <para>
2400 Change the <link linkend="sql-syntax-row-constructors">row
2401 constructor syntax</link> (<literal>ROW(...)</>) so that
2402 list elements <literal>foo.*</> will be expanded to a list
2403 of their member fields, rather than creating a nested
2404 row type field as formerly (Tom)
2405 </para>
2407 <para>
2408 The new behavior is substantially more useful since it
2409 allows, for example, triggers to check for data changes
2410 with <literal>IF row(new.*) IS DISTINCT FROM row(old.*)</>.
2411 The old behavior is still available by omitting <literal>.*</>.
2412 </para>
2413 </listitem>
2415 <listitem>
2416 <para>
2417 Make <link linkend="row-wise-comparison">row comparisons</link>
2418 follow <acronym>SQL</> standard semantics and allow them
2419 to be used in index scans (Tom)
2420 </para>
2422 <para>
2423 Previously, row = and &lt;&gt; comparisons followed the
2424 standard but &lt; &lt;= &gt; &gt;= did not. A row comparison
2425 can now be used as an index constraint for a multicolumn
2426 index matching the row value.
2427 </para>
2428 </listitem>
2430 <listitem>
2431 <para>
2432 Make <link linkend="functions-comparison">row <literal>IS <optional>NOT</> NULL</literal></link>
2433 tests follow <acronym>SQL</> standard semantics (Tom)
2434 </para>
2436 <para>
2437 The former behavior conformed to the standard for simple cases
2438 with <literal>IS NULL</>, but <literal>IS NOT NULL</> would return
2439 true if any row field was non-null, whereas the standard says it
2440 should return true only when all fields are non-null.
2441 </para>
2442 </listitem>
2444 <listitem>
2445 <para>
2446 Make <link linkend="SQL-SET-CONSTRAINTS"><command>SET
2447 CONSTRAINT</></link> affect only one constraint (Kris Jurka)
2448 </para>
2450 <para>
2451 In previous releases, <command>SET CONSTRAINT</> modified
2452 all constraints with a matching name. In this release,
2453 the schema search path is used to modify only the first
2454 matching constraint. A schema specification is also
2455 supported. This more nearly conforms to the SQL standard.
2456 </para>
2457 </listitem>
2459 <listitem>
2460 <para>
2461 Remove <literal>RULE</> permission for tables, for security reasons
2462 (Tom)
2463 </para>
2465 <para>
2466 As of this release, only a table's owner can create or modify
2467 rules for the table. For backwards compatibility,
2468 <command>GRANT</>/<command>REVOKE RULE</> is still accepted,
2469 but it does nothing.
2470 </para>
2471 </listitem>
2473 <listitem>
2474 <para>
2475 Array comparison improvements (Tom)
2476 </para>
2478 <para>
2479 Now array dimensions are also compared.
2480 </para>
2481 </listitem>
2483 <listitem>
2484 <para>
2485 Change <link linkend="functions-array">array concatenation</link>
2486 to match documented behavior (Tom)
2487 </para>
2489 <para>
2490 This changes the previous behavior where concatenation
2491 would modify the array lower bound.
2492 </para>
2493 </listitem>
2495 <listitem>
2496 <para>
2497 Make command-line options of <application>postmaster</>
2498 and <link linkend="app-postgres"><application>postgres</></link>
2499 identical (Peter)
2500 </para>
2502 <para>
2503 This allows the postmaster to pass arguments to each backend
2504 without using <literal>-o</>. Note that some options are now
2505 only available as long-form options, because there were conflicting
2506 single-letter options.
2507 </para>
2508 </listitem>
2510 <listitem>
2511 <para>
2512 Deprecate use of <application>postmaster</> symbolic link (Peter)
2513 </para>
2515 <para>
2516 <application>postmaster</> and <application>postgres</>
2517 commands now act identically, with the behavior determined
2518 by command-line options. The <application>postmaster</> symbolic link is
2519 kept for compatibility, but is not really needed.
2520 </para>
2521 </listitem>
2523 <listitem>
2524 <para>
2525 Change <link
2526 linkend="guc-log-duration"><varname>log_duration</></link>
2527 to output even if the query is not output (Tom)
2528 </para>
2530 <para>
2531 In prior releases, <varname>log_duration</> only printed if
2532 the query appeared earlier in the log.
2533 </para>
2534 </listitem>
2536 <listitem>
2537 <para>
2538 Make <link
2539 linkend="functions-formatting"><function>to_char(time)</></link>
2540 and <link
2541 linkend="functions-formatting"><function>to_char(interval)</></link>
2542 treat <literal>HH</> and <literal>HH12</> as 12-hour
2543 intervals
2544 </para>
2546 <para>
2547 Most applications should use <literal>HH24</> unless they
2548 want a 12-hour display.
2549 </para>
2550 </listitem>
2552 <listitem>
2553 <para>
2554 Zero unmasked bits in conversion from <link
2555 linkend="datatype-inet"><type>INET</></link> to <link
2556 linkend="datatype-inet"><type>CIDR</></link> (Tom)
2557 </para>
2559 <para>
2560 This ensures that the converted value is actually valid for
2561 <type>CIDR</>.
2562 </para>
2563 </listitem>
2565 <listitem>
2566 <para>
2567 Remove <varname>australian_timezones</> configuration variable
2568 (Joachim Wieland)
2569 </para>
2571 <para>
2572 This variable has been superseded by a more general facility
2573 for configuring timezone abbreviations.
2574 </para>
2575 </listitem>
2577 <listitem>
2578 <para>
2579 Improve cost estimation for nested-loop index scans (Tom)
2580 </para>
2582 <para>
2583 This might eliminate the need to set unrealistically small
2584 values of <link
2585 linkend="guc-random-page-cost"><varname>random_page_cost</></link>.
2586 If you have been using a very small <varname>random_page_cost</>,
2587 please recheck your test cases.
2588 </para>
2589 </listitem>
2591 <listitem>
2592 <para>
2593 Change behavior of <command>pg_dump</> <literal>-n</> and
2594 <literal>-t</> options. (Greg Sabino Mullane)
2595 </para>
2596 <para>
2597 See the <command>pg_dump</> manual page for details.
2598 </para>
2599 </listitem>
2601 <listitem>
2602 <para>
2603 Change <link linkend="libpq"><application>libpq</></link>
2604 <function>PQdsplen()</> to return a useful value (Martijn
2605 van Oosterhout)
2606 </para>
2607 </listitem>
2609 <listitem>
2610 <para>
2611 Declare <link linkend="libpq"><application>libpq</></link>
2612 <function>PQgetssl()</> as returning <literal>void *</>,
2613 rather than <literal>SSL *</> (Martijn van Oosterhout)
2614 </para>
2616 <para>
2617 This allows applications to use the function without including
2618 the OpenSSL headers.
2619 </para>
2620 </listitem>
2622 <listitem>
2623 <para>
2624 C-language loadable modules must now include a
2625 <link linkend="xfunc-c-dynload"><literal>PG_MODULE_MAGIC</></link>
2626 macro call for version compatibility checking
2627 (Martijn van Oosterhout)
2628 </para>
2629 </listitem>
2631 <listitem>
2632 <para>
2633 For security's sake, modules used by a PL/PerlU function are no
2634 longer available to PL/Perl functions (Andrew)
2635 </para>
2636 <note>
2637 <para>
2638 This also implies that data can no longer be shared between a PL/Perl
2639 function and a PL/PerlU function.
2640 Some Perl installations have not been compiled with the correct flags
2641 to allow multiple interpreters to exist within a single process.
2642 In this situation PL/Perl and PL/PerlU cannot both be used in a
2643 single backend. The solution is to get a Perl installation which
2644 supports multiple interpreters.
2645 </para>
2646 </note>
2647 </listitem>
2649 <listitem>
2650 <para>
2651 In <filename>contrib/xml2/</>, rename <function>xml_valid()</> to
2652 <function>xml_is_well_formed()</> (Tom)
2653 </para>
2655 <para>
2656 <function>xml_valid()</> will remain for backward compatibility,
2657 but its behavior will change to do schema checking in a future
2658 release.
2659 </para>
2660 </listitem>
2662 <listitem>
2663 <para>
2664 Remove <filename>contrib/ora2pg/</>, now at <ulink
2665 url="http://www.samse.fr/GPL/ora2pg"></ulink>
2666 </para>
2667 </listitem>
2669 <listitem>
2670 <para>
2671 Remove contrib modules that have been migrated to PgFoundry:
2672 <filename>adddepend</>, <filename>dbase</>, <filename>dbmirror</>,
2673 <filename>fulltextindex</>, <filename>mac</>, <filename>userlock</>
2674 </para>
2675 </listitem>
2677 <listitem>
2678 <para>
2679 Remove abandoned contrib modules:
2680 <filename>mSQL-interface</>, <filename>tips</>
2681 </para>
2682 </listitem>
2684 <listitem>
2685 <para>
2686 Remove <acronym>QNX</> and <acronym>BEOS</> ports (Bruce)
2687 </para>
2689 <para>
2690 These ports no longer had active maintainers.
2691 </para>
2692 </listitem>
2694 </itemizedlist>
2695 </sect2>
2697 <sect2>
2698 <title>Changes</title>
2700 <para>
2701 Below you will find a detailed account of the
2702 changes between <productname>PostgreSQL</productname> 8.2 and
2703 the previous major release.
2704 </para>
2706 <sect3>
2707 <title>Performance Improvements</title>
2708 <itemizedlist>
2710 <listitem>
2711 <para>
2712 Allow the planner to reorder <link linkend="queries-join">outer
2713 joins</link> in some circumstances (Tom)
2714 </para>
2716 <para>
2717 In previous releases, outer joins would always be evaluated in
2718 the order written in the query. This change allows the
2719 query optimizer to consider reordering outer joins, in cases where
2720 it can determine that the join order can be changed without
2721 altering the meaning of the query. This can make a
2722 considerable performance difference for queries involving
2723 multiple outer joins or mixed inner and outer joins.
2724 </para>
2725 </listitem>
2727 <listitem>
2728 <para>
2729 Improve efficiency of <link
2730 linkend="functions-comparisons"><literal>IN</>
2731 (list-of-expressions)</link> clauses (Tom)
2732 </para>
2733 </listitem>
2735 <listitem>
2736 <para>
2737 Improve sorting speed and reduce memory usage (Simon, Tom)
2738 </para>
2739 </listitem>
2741 <listitem>
2742 <para>
2743 Improve subtransaction performance (Alvaro, Itagaki Takahiro,
2744 Tom)
2745 </para>
2746 </listitem>
2748 <listitem>
2749 <para>
2750 Add <literal>FILLFACTOR</> to <link
2751 linkend="SQL-CREATETABLE">table</link> and <link
2752 linkend="SQL-CREATEINDEX">index</link> creation (ITAGAKI
2753 Takahiro)
2754 </para>
2756 <para>
2757 This leaves extra free space in each table or index page,
2758 allowing improved performance as the database grows. This
2759 is particularly valuable to maintain clustering.
2760 </para>
2761 </listitem>
2763 <listitem>
2764 <para>
2765 Increase default values for <link
2766 linkend="guc-shared-buffers"><varname>shared_buffers</></link>
2767 and <varname>max_fsm_pages</>
2768 (Andrew)
2769 </para>
2770 </listitem>
2772 <listitem>
2773 <para>
2774 Improve locking performance by breaking the lock manager tables into
2775 sections
2776 (Tom)
2777 </para>
2779 <para>
2780 This allows locking to be more fine-grained, reducing
2781 contention.
2782 </para>
2783 </listitem>
2785 <listitem>
2786 <para>
2787 Reduce locking requirements of sequential scans (Qingqing
2788 Zhou)
2789 </para>
2790 </listitem>
2792 <listitem>
2793 <para>
2794 Reduce locking required for database creation and destruction
2795 (Tom)
2796 </para>
2797 </listitem>
2799 <listitem>
2800 <para>
2801 Improve the optimizer's selectivity estimates for <link
2802 linkend="functions-like"><literal>LIKE</></link>, <link
2803 linkend="functions-like"><literal>ILIKE</></link>, and
2804 <link linkend="functions-posix-regexp">regular expression</link>
2805 operations (Tom)
2806 </para>
2807 </listitem>
2809 <listitem>
2810 <para>
2811 Improve planning of joins to <link linkend="ddl-inherit">inherited
2812 tables</link> and <link linkend="queries-union"><literal>UNION
2813 ALL</></link> views (Tom)
2814 </para>
2815 </listitem>
2817 <listitem>
2818 <para>
2819 Allow <link linkend="guc-constraint-exclusion">constraint
2820 exclusion</link> to be applied to <link
2821 linkend="ddl-inherit">inherited</link> <command>UPDATE</> and
2822 <command>DELETE</> queries (Tom)
2823 </para>
2825 <para>
2826 <command>SELECT</> already honored constraint exclusion.
2827 </para>
2828 </listitem>
2830 <listitem>
2831 <para>
2832 Improve planning of constant <literal>WHERE</> clauses, such as
2833 a condition that depends only on variables inherited from an
2834 outer query level (Tom)
2835 </para>
2836 </listitem>
2838 <listitem>
2839 <para>
2840 Protocol-level unnamed prepared statements are re-planned
2841 for each set of <literal>BIND</> values (Tom)
2842 </para>
2844 <para>
2845 This improves performance because the exact parameter values
2846 can be used in the plan.
2847 </para>
2848 </listitem>
2850 <listitem>
2851 <para>
2852 Speed up vacuuming of B-Tree indexes (Heikki Linnakangas,
2853 Tom)
2854 </para>
2855 </listitem>
2857 <listitem>
2858 <para>
2859 Avoid extra scan of tables without indexes during <link
2860 linkend="SQL-VACUUM"><command>VACUUM</></link> (Greg Stark)
2861 </para>
2862 </listitem>
2864 <listitem>
2865 <para>
2866 Improve multicolumn <link linkend="GiST"><acronym>GiST</></link>
2867 indexing (Oleg, Teodor)
2868 </para>
2869 </listitem>
2871 <listitem>
2872 <para>
2873 Remove dead index entries before B-Tree page split (Junji
2874 Teramoto)
2875 </para>
2876 </listitem>
2878 </itemizedlist>
2880 </sect3>
2882 <sect3>
2883 <title>Server Changes</title>
2884 <itemizedlist>
2886 <listitem>
2887 <para>
2888 Allow a forced switch to a new transaction log file (Simon, Tom)
2889 </para>
2891 <para>
2892 This is valuable for keeping warm standby slave servers
2893 in sync with the master. Transaction log file switching now also happens
2894 automatically during <link
2895 linkend="functions-admin"><function>pg_stop_backup()</></link>.
2896 This ensures that all
2897 transaction log files needed for recovery can be archived immediately.
2898 </para>
2899 </listitem>
2901 <listitem>
2902 <para>
2903 Add <acronym>WAL</> informational functions (Simon)
2904 </para>
2906 <para>
2907 Add functions for interrogating the current transaction log insertion
2908 point and determining <acronym>WAL</> filenames from the
2909 hex <acronym>WAL</> locations displayed by <link
2910 linkend="functions-admin"><function>pg_stop_backup()</></link>
2911 and related functions.
2912 </para>
2913 </listitem>
2915 <listitem>
2916 <para>
2917 Improve recovery from a crash during <acronym>WAL</> replay (Simon)
2918 </para>
2920 <para>
2921 The server now does periodic checkpoints during <acronym>WAL</>
2922 recovery, so if there is a crash, future <acronym>WAL</>
2923 recovery is shortened. This also eliminates the need for
2924 warm standby servers to replay the entire log since the
2925 base backup if they crash.
2926 </para>
2927 </listitem>
2929 <listitem>
2930 <para>
2931 Improve reliability of long-term <acronym>WAL</> replay
2932 (Heikki, Simon, Tom)
2933 </para>
2935 <para>
2936 Formerly, trying to roll forward through more than 2 billion
2937 transactions would not work due to XID wraparound. This meant
2938 warm standby servers had to be reloaded
2939 from fresh base backups periodically.
2940 </para>
2941 </listitem>
2943 <listitem>
2944 <para>
2945 Add <link
2946 linkend="guc-archive-timeout"><varname>archive_timeout</></link>
2947 to force transaction log file switches at a given interval (Simon)
2948 </para>
2950 <para>
2951 This enforces a maximum replication delay for warm standby servers.
2952 </para>
2953 </listitem>
2955 <listitem>
2956 <para>
2957 Add native <link linkend="auth-ldap"><acronym>LDAP</></link>
2958 authentication (Magnus Hagander)
2959 </para>
2961 <para>
2962 This is particularly useful for platforms that do not
2963 support <acronym>PAM</>, such as Windows.
2964 </para>
2965 </listitem>
2967 <listitem>
2968 <para>
2969 Add <link linkend="sql-grant-description-objects"><literal>GRANT
2970 CONNECT ON DATABASE</></link> (Gevik Babakhani)
2971 </para>
2973 <para>
2974 This gives SQL-level control over database access. It works as
2975 an additional filter on top of the existing
2976 <link linkend="auth-pg-hba-conf"><filename>pg_hba.conf</></link>
2977 controls.
2978 </para>
2979 </listitem>
2981 <listitem>
2982 <para>
2983 Add support for <link linkend="ssl-tcp"><acronym>SSL</>
2984 Certificate Revocation List</link> (<acronym>CRL</>) files
2985 (Libor Hoho&scaron;)
2986 </para>
2988 <para>
2989 The server and <application>libpq</> both recognize <acronym>CRL</>
2990 files now.
2991 </para>
2992 </listitem>
2994 <listitem>
2995 <para>
2996 <link linkend="GiST"><acronym>GiST</></link> indexes are
2997 now clusterable (Teodor)
2998 </para>
2999 </listitem>
3001 <listitem>
3002 <para>
3003 Remove routine autovacuum server log entries (Bruce)
3004 </para>
3006 <para>
3007 <link
3008 linkend="monitoring-stats-views-table"><literal>pg_stat_activity</></link>
3009 now shows autovacuum activity.
3010 </para>
3011 </listitem>
3013 <listitem>
3014 <para>
3015 Track maximum XID age within individual tables, instead of whole databases (Alvaro)
3016 </para>
3018 <para>
3019 This reduces the overhead involved in preventing transaction
3020 ID wraparound, by avoiding unnecessary VACUUMs.
3021 </para>
3022 </listitem>
3024 <listitem>
3025 <para>
3026 Add last vacuum and analyze timestamp columns to the stats
3027 collector (Larry Rosenman)
3028 </para>
3030 <para>
3031 These values now appear in the <link
3032 linkend="monitoring-stats-views-table"><literal>pg_stat_*_tables</></link>
3033 system views.
3034 </para>
3035 </listitem>
3037 <listitem>
3038 <para>
3039 Improve performance of statistics monitoring, especially
3040 <varname>stats_command_string</>
3041 (Tom, Bruce)
3042 </para>
3044 <para>
3045 This release enables <varname>stats_command_string</> by
3046 default, now that its overhead is minimal. This means
3047 <link
3048 linkend="monitoring-stats-views-table"><literal>pg_stat_activity</></link>
3049 will now show all active queries by default.
3050 </para>
3051 </listitem>
3053 <listitem>
3054 <para>
3055 Add a <literal>waiting</> column to <link
3056 linkend="monitoring-stats-views-table"><literal>pg_stat_activity</></link>
3057 (Tom)
3058 </para>
3060 <para>
3061 This allows <structname>pg_stat_activity</> to show all the
3062 information included in the <application>ps</> display.
3063 </para>
3064 </listitem>
3066 <listitem>
3067 <para>
3068 Add configuration parameter <link
3069 linkend="guc-update-process-title"><varname>update_process_title</></link>
3070 to control whether the <application>ps</> display is updated
3071 for every command (Bruce)
3072 </para>
3074 <para>
3075 On platforms where it is expensive to update the <application>ps</>
3076 display, it might be worthwhile to turn this off and rely solely on
3077 <structname>pg_stat_activity</> for status information.
3078 </para>
3079 </listitem>
3081 <listitem>
3082 <para>
3083 Allow units to be specified in configuration settings
3084 (Peter)
3085 </para>
3087 <para>
3088 For example, you can now set <link
3089 linkend="guc-shared-buffers"><varname>shared_buffers</></link>
3090 to <literal>32MB</> rather than mentally converting sizes.
3091 </para>
3092 </listitem>
3094 <listitem>
3095 <para>
3096 Add support for <link linkend="config-setting">include
3097 directives</link> in <filename>postgresql.conf</> (Joachim
3098 Wieland)
3099 </para>
3100 </listitem>
3102 <listitem>
3103 <para>
3104 Improve logging of protocol-level prepare/bind/execute
3105 messages (Bruce, Tom)
3106 </para>
3108 <para>
3109 Such logging now shows statement names, bind parameter
3110 values, and the text of the query being executed. Also,
3111 the query text is properly included in logged error messages
3112 when enabled by <varname>log_min_error_statement</>.
3113 </para>
3114 </listitem>
3116 <listitem>
3117 <para>
3118 Prevent <link
3119 linkend="guc-max-stack-depth"><varname>max_stack_depth</></link>
3120 from being set to unsafe values
3121 </para>
3123 <para>
3124 On platforms where we can determine the actual kernel stack depth
3125 limit (which is most), make sure that the initial default value of
3126 <varname>max_stack_depth</> is safe, and reject attempts to set it
3127 to unsafely large values.
3128 </para>
3129 </listitem>
3131 <listitem>
3132 <para>
3133 Enable highlighting of error location in query in more
3134 cases (Tom)
3135 </para>
3137 <para>
3138 The server is now able to report a specific error location for
3139 some semantic errors (such as unrecognized column name), rather
3140 than just for basic syntax errors as before.
3141 </para>
3142 </listitem>
3144 <listitem>
3145 <para>
3146 Fix <quote>failed to re-find parent key</> errors in
3147 <command>VACUUM</> (Tom)
3148 </para>
3149 </listitem>
3151 <listitem>
3152 <para>
3153 Clean out <filename>pg_internal.init</> cache files during server
3154 restart (Simon)
3155 </para>
3157 <para>
3158 This avoids a hazard that the cache files might contain stale
3159 data after PITR recovery.
3160 </para>
3161 </listitem>
3163 <listitem>
3164 <para>
3165 Fix race condition for truncation of a large relation across a
3166 gigabyte boundary by <command>VACUUM</> (Tom)
3167 </para>
3168 </listitem>
3170 <listitem>
3171 <para>
3172 Fix bug causing needless deadlock errors on row-level locks (Tom)
3173 </para>
3174 </listitem>
3176 <listitem>
3177 <para>
3178 Fix bugs affecting multi-gigabyte hash indexes (Tom)
3179 </para>
3180 </listitem>
3182 <listitem>
3183 <para>
3184 Each backend process is now its own process group leader (Tom)
3185 </para>
3187 <para>
3188 This allows query cancel to abort subprocesses invoked from a
3189 backend or archive/recovery process.
3190 </para>
3191 </listitem>
3193 </itemizedlist>
3195 </sect3>
3197 <sect3>
3198 <title>Query Changes</title>
3199 <itemizedlist>
3201 <listitem>
3202 <para>
3203 Add <link linkend="SQL-INSERT"><command>INSERT</></link>/<link
3204 linkend="SQL-UPDATE"><command>UPDATE</></link>/<link
3205 linkend="SQL-DELETE"><command>DELETE</></link>
3206 <literal>RETURNING</> (Jonah Harris, Tom)
3207 </para>
3209 <para>
3210 This allows these commands to return values, such as the
3211 computed serial key for a new row. In the <command>UPDATE</>
3212 case, values from the updated version of the row are returned.
3213 </para>
3214 </listitem>
3216 <listitem>
3217 <para>
3218 Add support for multiple-row <link
3219 linkend="queries-values"><literal>VALUES</></link> clauses,
3220 per SQL standard (Joe, Tom)
3221 </para>
3223 <para>
3224 This allows <command>INSERT</> to insert multiple rows of
3225 constants, or queries to generate result sets using constants.
3226 For example, <literal>INSERT ... VALUES (...), (...),
3227 ....</>, and <literal>SELECT * FROM (VALUES (...), (...),
3228 ....) AS alias(f1, ...)</>.
3229 </para>
3230 </listitem>
3232 <listitem>
3233 <para>
3234 Allow <link linkend="SQL-UPDATE"><command>UPDATE</></link>
3235 and <link linkend="SQL-DELETE"><command>DELETE</></link>
3236 to use an alias for the target table (Atsushi Ogawa)
3237 </para>
3239 <para>
3240 The SQL standard does not permit an alias in these commands, but
3241 many database systems allow one anyway for notational convenience.
3242 </para>
3243 </listitem>
3245 <listitem>
3246 <para>
3247 Allow <link linkend="SQL-UPDATE"><command>UPDATE</></link>
3248 to set multiple columns with a list of values (Susanne
3249 Ebrecht)
3250 </para>
3252 <para>
3253 This is basically a short-hand for assigning the columns
3254 and values in pairs. The syntax is <literal>UPDATE tab
3255 SET (<replaceable>column</>, ...) = (<replaceable>val</>, ...)</>.
3256 </para>
3257 </listitem>
3259 <listitem>
3260 <para>
3261 Make row comparisons work per standard (Tom)
3262 </para>
3264 <para>
3265 The forms &lt;, &lt;=, &gt;, &gt;= now compare rows lexicographically,
3266 that is, compare the first elements, if equal compare the second
3267 elements, and so on. Formerly they expanded to an AND condition
3268 across all the elements, which was neither standard nor very useful.
3269 </para>
3270 </listitem>
3272 <listitem>
3273 <para>
3274 Add <link linkend="SQL-TRUNCATE"><literal>CASCADE</></link>
3275 option to <command>TRUNCATE</> (Joachim Wieland)
3276 </para>
3278 <para>
3279 This causes <command>TRUNCATE</> to automatically include all tables
3280 that reference the specified table(s) via foreign keys. While
3281 convenient, this is a dangerous tool &mdash; use with caution!
3282 </para>
3283 </listitem>
3285 <listitem>
3286 <para>
3287 Support <literal>FOR UPDATE</> and <literal>FOR SHARE</>
3288 in the same <link linkend="SQL-INSERT"><literal>SELECT</></link>
3289 command (Tom)
3290 </para>
3291 </listitem>
3293 <listitem>
3294 <para>
3295 Add <link linkend="functions-comparisons"><literal>IS NOT
3296 DISTINCT FROM</></link> (Pavel Stehule)
3297 </para>
3299 <para>
3300 This operator is similar to equality (<literal>=</>), but
3301 evaluates to true when both left and right operands are
3302 <literal>NULL</>, and to false when just one is, rather than
3303 yielding <literal>NULL</> in these cases.
3304 </para>
3305 </listitem>
3307 <listitem>
3308 <para>
3309 Improve the length output used by <link
3310 linkend="queries-union"><literal>UNION</></link>/<literal>INTERSECT</>/<literal>EXCEPT</>
3311 (Tom)
3312 </para>
3314 <para>
3315 When all corresponding columns are of the same defined length, that
3316 length is used for the result, rather than a generic length.
3317 </para>
3318 </listitem>
3320 <listitem>
3321 <para>
3322 Allow <link linkend="functions-like"><literal>ILIKE</></link>
3323 to work for multi-byte encodings (Tom)
3324 </para>
3326 <para>
3327 Internally, <literal>ILIKE</> now calls <function>lower()</>
3328 and then uses <literal>LIKE</>. Locale-specific regular
3329 expression patterns still do not work in these encodings.
3330 </para>
3331 </listitem>
3333 <listitem>
3334 <para>
3335 Enable <link
3336 linkend="guc-standard-conforming-strings"><varname>standard_conforming_strings</></link>
3337 to be turned <literal>on</> (Kevin Grittner)
3338 </para>
3340 <para>
3341 This allows backslash escaping in strings to be disabled,
3342 making <productname>PostgreSQL</> more
3343 standards-compliant. The default is <literal>off</> for backwards
3344 compatibility, but future releases will default this to <literal>on</>.
3345 </para>
3346 </listitem>
3348 <listitem>
3349 <para>
3350 Do not flatten subqueries that contain <literal>volatile</>
3351 functions in their target lists (Jaime Casanova)
3352 </para>
3354 <para>
3355 This prevents surprising behavior due to multiple evaluation
3356 of a <literal>volatile</> function (such as <function>random()</>
3357 or <function>nextval()</>). It might cause performance
3358 degradation in the presence of functions that are unnecessarily
3359 marked as <literal>volatile</>.
3360 </para>
3361 </listitem>
3363 <listitem>
3364 <para>
3365 Add system views <link
3366 linkend="view-pg-prepared-statements"><literal>pg_prepared_statements</></link>
3367 and <link
3368 linkend="view-pg-cursors"><literal>pg_cursors</></link>
3369 to show prepared statements and open cursors (Joachim Wieland, Neil)
3370 </para>
3372 <para>
3373 These are very useful in pooled connection setups.
3374 </para>
3375 </listitem>
3377 <listitem>
3378 <para>
3379 Support portal parameters in <link
3380 linkend="SQL-EXPLAIN"><command>EXPLAIN</></link> and <link
3381 linkend="SQL-EXECUTE"><command>EXECUTE</></link> (Tom)
3382 </para>
3384 <para>
3385 This allows, for example, <acronym>JDBC</> <literal>?</> parameters to
3386 work in these commands.
3387 </para>
3388 </listitem>
3390 <listitem>
3391 <para>
3392 If <acronym>SQL</>-level <link
3393 linkend="SQL-PREPARE"><command>PREPARE</></link> parameters
3394 are unspecified, infer their types from the content of the
3395 query (Neil)
3396 </para>
3398 <para>
3399 Protocol-level <command>PREPARE</> already did this.
3400 </para>
3401 </listitem>
3403 <listitem>
3404 <para>
3405 Allow <literal>LIMIT</> and <literal>OFFSET</> to exceed
3406 two billion (Dhanaraj M)
3407 </para>
3408 </listitem>
3410 </itemizedlist>
3412 </sect3>
3414 <sect3>
3415 <title>Object Manipulation Changes</title>
3416 <itemizedlist>
3418 <listitem>
3419 <para>
3420 Add <literal>TABLESPACE</> clause to <link
3421 linkend="SQL-CREATETABLEAS"><command>CREATE TABLE AS</></link>
3422 (Neil)
3423 </para>
3425 <para>
3426 This allows a tablespace to be specified for the new table.
3427 </para>
3428 </listitem>
3430 <listitem>
3431 <para>
3432 Add <literal>ON COMMIT</> clause to <link
3433 linkend="SQL-CREATETABLEAS"><command>CREATE TABLE AS</></link>
3434 (Neil)
3435 </para>
3437 <para>
3438 This allows temporary tables to be truncated or dropped on
3439 transaction commit. The default behavior is for the table
3440 to remain until the session ends.
3441 </para>
3442 </listitem>
3444 <listitem>
3445 <para>
3446 Add <literal>INCLUDING CONSTRAINTS</> to <link
3447 linkend="SQL-CREATETABLE"><command>CREATE TABLE LIKE</></link>
3448 (Greg Stark)
3449 </para>
3451 <para>
3452 This allows easy copying of <literal>CHECK</> constraints to a new
3453 table.
3454 </para>
3455 </listitem>
3457 <listitem>
3458 <para>
3459 Allow the creation of placeholder (shell) <link
3460 linkend="SQL-CREATETYPE">types</link> (Martijn van Oosterhout)
3461 </para>
3463 <para>
3464 A shell type declaration creates a type name, without specifying
3465 any of the details of the type. Making a shell type is useful
3466 because it allows cleaner declaration of the type's input/output
3467 functions, which must exist before the type can be defined <quote>for
3468 real</>. The syntax is <command>CREATE TYPE <replaceable
3469 class="parameter">typename</replaceable></>.
3470 </para>
3471 </listitem>
3473 <listitem>
3474 <para>
3475 <link linkend="SQL-CREATEAGGREGATE">Aggregate functions</link>
3476 now support multiple input parameters (Sergey Koposov, Tom)
3477 </para>
3478 </listitem>
3480 <listitem>
3481 <para>
3482 Add new aggregate creation <link
3483 linkend="SQL-CREATEAGGREGATE">syntax</link> (Tom)
3484 </para>
3486 <para>
3487 The new syntax is <command>CREATE AGGREGATE
3488 <replaceable>aggname</> (<replaceable>input_type</>)
3489 (<replaceable>parameter_list</>)</command>. This more
3490 naturally supports the new multi-parameter aggregate
3491 functionality. The previous syntax is still supported.
3492 </para>
3493 </listitem>
3495 <listitem>
3496 <para>
3497 Add <link
3498 linkend="SQL-ALTERROLE"><command>ALTER ROLE PASSWORD NULL</></link>
3499 to remove a previously set role password (Peter)
3500 </para>
3501 </listitem>
3503 <listitem>
3504 <para>
3505 Add <command>DROP</> object <literal>IF EXISTS</> for many
3506 object types (Andrew)
3507 </para>
3509 <para>
3510 This allows <command>DROP</> operations on non-existent
3511 objects without generating an error.
3512 </para>
3513 </listitem>
3515 <listitem>
3516 <para>
3517 Add <link linkend="SQL-DROP-OWNED"><literal>DROP OWNED</></link>
3518 to drop all objects owned by a role (Alvaro)
3519 </para>
3520 </listitem>
3522 <listitem>
3523 <para>
3524 Add <link linkend="SQL-REASSIGN-OWNED"><literal>REASSIGN
3525 OWNED</></link> to reassign ownership of all objects owned
3526 by a role (Alvaro)
3527 </para>
3529 <para>
3530 This, and <literal>DROP OWNED</> above, facilitate dropping
3531 roles.
3532 </para>
3533 </listitem>
3535 <listitem>
3536 <para>
3537 Add <link linkend="SQL-GRANT"><command>GRANT ON SEQUENCE</></link>
3538 syntax (Bruce)
3539 </para>
3541 <para>
3542 This was added for setting sequence-specific permissions.
3543 <literal>GRANT ON TABLE</> for sequences is still supported
3544 for backward compatibility.
3545 </para>
3546 </listitem>
3548 <listitem>
3549 <para>
3550 Add <link linkend="SQL-GRANT"><literal>USAGE</></link>
3551 permission for sequences that allows only <function>currval()</>
3552 and <function>nextval()</>, not <function>setval()</>
3553 (Bruce)
3554 </para>
3556 <para>
3557 <literal>USAGE</> permission allows more fine-grained
3558 control over sequence access. Granting <literal>USAGE</>
3559 allows users to increment
3560 a sequence, but prevents them from setting the sequence to
3561 an arbitrary value using <function>setval()</>.
3562 </para>
3563 </listitem>
3565 <listitem>
3566 <para>
3567 Add <link linkend="SQL-ALTERTABLE"><literal>ALTER TABLE
3568 [ NO ] INHERIT</></link> (Greg Stark)
3569 </para>
3571 <para>
3572 This allows inheritance to be adjusted dynamically, rather than
3573 just at table creation and destruction. This is very valuable
3574 when using inheritance to implement table partitioning.
3575 </para>
3576 </listitem>
3578 <listitem>
3579 <para>
3580 Allow <link linkend="SQL-COMMENT">comments</link> on global
3581 objects to be stored globally (Kris Jurka)
3582 </para>
3584 <para>
3585 Previously, comments attached to databases were stored in individual
3586 databases, making them ineffective, and there was no provision
3587 at all for comments on roles or tablespaces. This change adds a new
3588 shared catalog <link
3589 linkend="catalog-pg-shdescription"><structname>pg_shdescription</structname></link>
3590 and stores comments on databases, roles, and tablespaces therein.
3591 </para>
3592 </listitem>
3594 </itemizedlist>
3596 </sect3>
3598 <sect3>
3599 <title>Utility Command Changes</title>
3600 <itemizedlist>
3602 <listitem>
3603 <para>
3604 Add option to allow indexes to be created without blocking
3605 concurrent writes to the table (Greg Stark, Tom)
3606 </para>
3608 <para>
3609 The new syntax is <link linkend="SQL-CREATEINDEX"><command>CREATE
3610 INDEX CONCURRENTLY</></link>. The default behavior is
3611 still to block table modification while a index is being
3612 created.
3613 </para>
3614 </listitem>
3616 <listitem>
3617 <para>
3618 Provide <link linkend="functions-advisory-locks">advisory
3619 locking</link> functionality (Abhijit Menon-Sen, Tom)
3620 </para>
3622 <para>
3623 This is a new locking API designed to replace what used to be
3624 in /contrib/userlock. The userlock code is now on pgfoundry.
3625 </para>
3626 </listitem>
3628 <listitem>
3629 <para>
3630 Allow <link linkend="SQL-COPY"><command>COPY</></link> to
3631 dump a <command>SELECT</> query (Zoltan Boszormenyi, Karel
3632 Zak)
3633 </para>
3635 <para>
3636 This allows <command>COPY</> to dump arbitrary <acronym>SQL</>
3637 queries. The syntax is <literal>COPY (SELECT ...) TO</>.
3638 </para>
3639 </listitem>
3641 <listitem>
3642 <para>
3643 Make the <link linkend="SQL-COPY"><command>COPY</></link>
3644 command return a command tag that includes the number of
3645 rows copied (Volkan YAZICI)
3646 </para>
3647 </listitem>
3649 <listitem>
3650 <para>
3651 Allow <link linkend="SQL-VACUUM"><command>VACUUM</></link>
3652 to expire rows without being affected by other concurrent
3653 <command>VACUUM</> operations (Hannu Krossing, Alvaro, Tom)
3654 </para>
3655 </listitem>
3657 <listitem>
3658 <para>
3659 Make <link linkend="APP-INITDB"><application>initdb</></link>
3660 detect the operating system locale and set the default
3661 <varname>DateStyle</> accordingly (Peter)
3662 </para>
3664 <para>
3665 This makes it more likely that the installed
3666 <filename>postgresql.conf</> <varname>DateStyle</> value will
3667 be as desired.
3668 </para>
3669 </listitem>
3671 <listitem>
3672 <para>
3673 Reduce number of progress messages displayed by <application>initdb</> (Tom)
3674 </para>
3675 </listitem>
3677 </itemizedlist>
3679 </sect3>
3681 <sect3>
3682 <title>Date/Time Changes</title>
3683 <itemizedlist>
3685 <listitem>
3686 <para>
3687 Allow full timezone names in <link
3688 linkend="datatype-datetime"><type>timestamp</></link> input values
3689 (Joachim Wieland)
3690 </para>
3692 <para>
3693 For example, <literal>'2006-05-24 21:11
3694 America/New_York'::timestamptz</>.
3695 </para>
3696 </listitem>
3698 <listitem>
3699 <para>
3700 Support configurable timezone abbreviations (Joachim Wieland)
3701 </para>
3703 <para>
3704 A desired set of timezone abbreviations can be chosen via the
3705 configuration parameter <link
3706 linkend="guc-timezone-abbreviations"><varname>timezone_abbreviations</></link>.
3707 </para>
3708 </listitem>
3710 <listitem>
3711 <para>
3712 Add <link
3713 linkend="view-pg-timezone-abbrevs"><varname>pg_timezone_abbrevs</></link>
3714 and <link
3715 linkend="view-pg-timezone-names"><varname>pg_timezone_names</></link>
3716 views to show supported timezones (Magnus Hagander)
3717 </para>
3718 </listitem>
3720 <listitem>
3721 <para>
3722 Add <link
3723 linkend="functions-datetime-table"><function>clock_timestamp()</></link>,
3724 <link
3725 linkend="functions-datetime-table"><function>statement_timestamp()</></link>,
3726 and <link
3727 linkend="functions-datetime-table"><function>transaction_timestamp()</></link>
3728 (Bruce)
3729 </para>
3731 <para>
3732 <function>clock_timestamp()</> is the current wall-clock time,
3733 <function>statement_timestamp()</> is the time the current
3734 statement arrived at the server, and
3735 <function>transaction_timestamp()</> is an alias for
3736 <function>now()</>.
3737 </para>
3738 </listitem>
3740 <listitem>
3741 <para>
3742 Allow <link
3743 linkend="functions-formatting"><function>to_char()</></link>
3744 to print localized month and day names (Euler Taveira de
3745 Oliveira)
3746 </para>
3747 </listitem>
3749 <listitem>
3750 <para>
3751 Allow <link
3752 linkend="functions-formatting"><function>to_char(time)</></link>
3753 and <link
3754 linkend="functions-formatting"><function>to_char(interval)</></link>
3755 to output <acronym>AM</>/<acronym>PM</> specifications
3756 (Bruce)
3757 </para>
3759 <para>
3760 Intervals and times are treated as 24-hour periods, e.g.
3761 <literal>25 hours</> is considered <acronym>AM</>.
3762 </para>
3763 </listitem>
3765 <listitem>
3766 <para>
3767 Add new function <link
3768 linkend="functions-datetime-table"><function>justify_interval()</></link>
3769 to adjust interval units (Mark Dilger)
3770 </para>
3771 </listitem>
3773 <listitem>
3774 <para>
3775 Allow timezone offsets up to 14:59 away from GMT
3776 </para>
3778 <para>
3779 Kiribati uses GMT+14, so we'd better accept that.
3780 </para>
3781 </listitem>
3783 <listitem>
3784 <para>
3785 Interval computation improvements (Michael Glaesemann, Bruce)
3786 </para>
3787 </listitem>
3789 </itemizedlist>
3791 </sect3>
3793 <sect3>
3794 <title>Other Data Type and Function Changes</title>
3795 <itemizedlist>
3797 <listitem>
3798 <para>
3799 Allow arrays to contain <literal>NULL</> elements (Tom)
3800 </para>
3801 </listitem>
3803 <listitem>
3804 <para>
3805 Allow assignment to array elements not contiguous with the existing
3806 entries (Tom)
3807 </para>
3809 <para>
3810 The intervening array positions will be filled with nulls.
3811 This is per SQL standard.
3812 </para>
3813 </listitem>
3815 <listitem>
3816 <para>
3817 New built-in <link linkend="functions-array">operators</link>
3818 for array-subset comparisons (<literal>@&gt;</>,
3819 <literal>&lt;@</>, <literal>&amp;&amp;</>) (Teodor, Tom)
3820 </para>
3822 <para>
3823 These operators can be indexed for many data types using
3824 <acronym>GiST</> or <acronym>GIN</> indexes.
3825 </para>
3826 </listitem>
3828 <listitem>
3829 <para>
3830 Add convenient arithmetic <link
3831 linkend="cidr-inet-operators-table">operations</link> on
3832 <type>INET</>/<type>CIDR</> values (Stephen R. van den
3833 Berg)
3834 </para>
3836 <para>
3837 The new operators are <literal>&amp;</> (and), <literal>|</>
3838 (or), <literal>~</> (not), <type>inet</> <literal>+</> <type>int8</>,
3839 <type>inet</> <literal>-</> <type>int8</>, and
3840 <type>inet</> <literal>-</> <type>inet</>.
3841 </para>
3842 </listitem>
3844 <listitem>
3845 <para>
3846 Add new <link
3847 linkend="functions-aggregate-statistics-table">aggregate functions</link>
3848 from SQL:2003 (Neil)
3849 </para>
3851 <para>
3852 The new functions are <function>var_pop()</>,
3853 <function>var_samp()</>, <function>stddev_pop()</>, and
3854 <function>stddev_samp()</>. <function>var_samp()</> and
3855 <function>stddev_samp()</> are merely renamings of the
3856 existing aggregates <function>variance()</> and
3857 <function>stddev()</>. The latter names remain available
3858 for backward compatibility.
3859 </para>
3860 </listitem>
3862 <listitem>
3863 <para>
3864 Add SQL:2003 statistical <link
3865 linkend="functions-aggregate-statistics-table">aggregates</link>
3866 (Sergey Koposov)
3867 </para>
3869 <para>
3870 New functions: <function>regr_intercept()</>,
3871 <function>regr_slope()</>, <function>regr_r2()</>,
3872 <function>corr()</>, <function>covar_samp()</>,
3873 <function>covar_pop()</>, <function>regr_avgx()</>,
3874 <function>regr_avgy()</>, <function>regr_sxy()</>,
3875 <function>regr_sxx()</>, <function>regr_syy()</>,
3876 <function>regr_count()</>.
3877 </para>
3878 </listitem>
3880 <listitem>
3881 <para>
3882 Allow <link linkend="SQL-CREATEDOMAIN">domains</link> to be
3883 based on other domains (Tom)
3884 </para>
3885 </listitem>
3887 <listitem>
3888 <para>
3889 Properly enforce domain <link
3890 linkend="ddl-constraints"><literal>CHECK</></link> constraints
3891 everywhere (Neil, Tom)
3892 </para>
3894 <para>
3895 For example, the result of a user-defined function that is
3896 declared to return a domain type is now checked against the
3897 domain's constraints. This closes a significant hole in the domain
3898 implementation.
3899 </para>
3900 </listitem>
3902 <listitem>
3903 <para>
3904 Fix problems with dumping renamed <link
3905 linkend="datatype-serial"><type>SERIAL</></link> columns
3906 (Tom)
3907 </para>
3909 <para>
3910 The fix is to dump a <type>SERIAL</> column by explicitly
3911 specifying its <literal>DEFAULT</> and sequence elements,
3912 and reconstructing the <type>SERIAL</> column on reload
3913 using a new <link linkend="SQL-ALTERSEQUENCE"><command>ALTER
3914 SEQUENCE OWNED BY</></link> command. This also allows
3915 dropping a <type>SERIAL</> column specification.
3916 </para>
3917 </listitem>
3919 <listitem>
3920 <para>
3921 Add a server-side sleep function <link
3922 linkend="functions-datetime-delay"><function>pg_sleep()</></link>
3923 (Joachim Wieland)
3924 </para>
3925 </listitem>
3927 <listitem>
3928 <para>
3929 Add all comparison operators for the <link
3930 linkend="datatype-oid"><type>tid</></link> (tuple id) data
3931 type (Mark Kirkwood, Greg Stark, Tom)
3932 </para>
3933 </listitem>
3935 </itemizedlist>
3937 </sect3>
3939 <sect3>
3940 <title>PL/PgSQL Server-Side Language Changes</title>
3941 <itemizedlist>
3943 <listitem>
3944 <para>
3945 Add <literal>TG_table_name</> and <literal>TG_table_schema</> to
3946 trigger parameters (Andrew)
3947 </para>
3949 <para>
3950 <literal>TG_relname</> is now deprecated. Comparable
3951 changes have been made in the trigger parameters for the other
3952 PLs as well.
3953 </para>
3954 </listitem>
3956 <listitem>
3957 <para>
3958 Allow <literal>FOR</> statements to return values to scalars
3959 as well as records and row types (Pavel Stehule)
3960 </para>
3961 </listitem>
3963 <listitem>
3964 <para>
3965 Add a <literal>BY</> clause to the <literal>FOR</> loop,
3966 to control the iteration increment (Jaime Casanova)
3967 </para>
3968 </listitem>
3970 <listitem>
3971 <para>
3972 Add <literal>STRICT</> to <link
3973 linkend="plpgsql-statements-sql-onerow"><command>SELECT
3974 INTO</></link> (Matt Miller)
3975 </para>
3977 <para>
3978 <literal>STRICT</> mode throws an exception if more or less
3979 than one row is returned by the <command>SELECT</>, for
3980 <productname>Oracle PL/SQL</> compatibility.
3981 </para>
3982 </listitem>
3984 </itemizedlist>
3986 </sect3>
3988 <sect3>
3989 <title>PL/Perl Server-Side Language Changes</title>
3990 <itemizedlist>
3992 <listitem>
3993 <para>
3994 Add <literal>table_name</> and <literal>table_schema</> to
3995 trigger parameters (Adam Sj&oslash;gren)
3996 </para>
3997 </listitem>
3999 <listitem>
4000 <para>
4001 Add prepared queries (Dmitry Karasik)
4002 </para>
4003 </listitem>
4005 <listitem>
4006 <para>
4007 Make <literal>$_TD</> trigger data a global variable (Andrew)
4008 </para>
4010 <para>
4011 Previously, it was lexical, which caused unexpected sharing
4012 violations.
4013 </para>
4014 </listitem>
4016 <listitem>
4017 <para>
4018 Run PL/Perl and PL/PerlU in separate interpreters, for security
4019 reasons (Andrew)
4020 </para>
4021 <para>
4022 In consequence, they can no longer share data nor loaded modules.
4023 Also, if Perl has not been compiled with the requisite flags to
4024 allow multiple interpreters, only one of these languages can be used
4025 in any given backend process.
4026 </para>
4027 </listitem>
4029 </itemizedlist>
4031 </sect3>
4033 <sect3>
4034 <title>PL/Python Server-Side Language Changes</title>
4035 <itemizedlist>
4037 <listitem>
4038 <para>
4039 Named parameters are passed as ordinary variables, as well as in the
4040 <literal>args[]</> array (Sven Suursoho)
4041 </para>
4042 </listitem>
4044 <listitem>
4045 <para>
4046 Add <literal>table_name</> and <literal>table_schema</> to
4047 trigger parameters (Andrew)
4048 </para>
4049 </listitem>
4051 <listitem>
4052 <para>
4053 Allow returning of composite types and result sets (Sven Suursoho)
4054 </para>
4055 </listitem>
4057 <listitem>
4058 <para>
4059 Return result-set as <literal>list</>, <literal>iterator</>,
4060 or <literal>generator </>(Sven Suursoho)
4061 </para>
4062 </listitem>
4064 <listitem>
4065 <para>
4066 Allow functions to return <literal>void</> (Neil)
4067 </para>
4068 </listitem>
4070 <listitem>
4071 <para>
4072 Python 2.5 is now supported (Tom)
4073 </para>
4074 </listitem>
4076 </itemizedlist>
4078 </sect3>
4080 <sect3>
4081 <title><link linkend="APP-PSQL"><application>psql</></link> Changes</title>
4082 <itemizedlist>
4084 <listitem>
4085 <para>
4086 Add new command <literal>\password</> for changing role
4087 password with client-side password encryption (Peter)
4088 </para>
4089 </listitem>
4091 <listitem>
4092 <para>
4093 Allow <literal>\c</> to connect to a new host and port
4094 number (David, Volkan YAZICI)
4095 </para>
4096 </listitem>
4098 <listitem>
4099 <para>
4100 Add tablespace display to <literal>\l+</> (Philip Yarra)
4101 </para>
4102 </listitem>
4104 <listitem>
4105 <para>
4106 Improve <literal>\df</> slash command to include the argument
4107 names and modes (<literal>OUT</> or <literal>INOUT</>) of
4108 the function (David Fetter)
4109 </para>
4110 </listitem>
4112 <listitem>
4113 <para>
4114 Support binary <command>COPY</> (Andreas Pflug)
4115 </para>
4116 </listitem>
4118 <listitem>
4119 <para>
4120 Add option to run the entire session in a single transaction
4121 (Simon)
4122 </para>
4124 <para>
4125 Use option <literal>-1</> or <literal>--single-transaction</>.
4126 </para>
4127 </listitem>
4129 <listitem>
4130 <para>
4131 Support for automatically retrieving <command>SELECT</>
4132 results in batches using a cursor (Chris Mair)
4133 </para>
4135 <para>
4136 This is enabled using <command>\set FETCH_COUNT
4137 <replaceable>n</></command>. This
4138 feature allows large result sets to be retrieved in
4139 <application>psql</> without attempting to buffer the entire
4140 result set in memory.
4141 </para>
4142 </listitem>
4144 <listitem>
4145 <para>
4146 Make multi-line values align in the proper column
4147 (Martijn van Oosterhout)
4148 </para>
4150 <para>
4151 Field values containing newlines are now displayed in a more
4152 readable fashion.
4153 </para>
4154 </listitem>
4156 <listitem>
4157 <para>
4158 Save multi-line statements as a single entry, rather than
4159 one line at a time (Sergey E. Koposov)
4160 </para>
4162 <para>
4163 This makes up-arrow recall of queries easier. (This is
4164 not available on Windows, because that platform uses the native
4165 command-line editing present in the operating system.)
4166 </para>
4167 </listitem>
4169 <listitem>
4170 <para>
4171 Make the line counter 64-bit so it can handle files with more
4172 than two billion lines (David Fetter)
4173 </para>
4174 </listitem>
4176 <listitem>
4177 <para>
4178 Report both the returned data and the command status tag
4179 for <command>INSERT</>/<command>UPDATE</>/<command>DELETE
4180 RETURNING</> (Tom)
4181 </para>
4182 </listitem>
4184 </itemizedlist>
4186 </sect3>
4188 <sect3>
4189 <title><link linkend="APP-PGDUMP"><application>pg_dump</></link> Changes</title>
4190 <itemizedlist>
4192 <listitem>
4193 <para>
4194 Allow complex selection of objects to be included or excluded
4195 by <application>pg_dump</> (Greg Sabino Mullane)
4196 </para>
4198 <para>
4199 <application>pg_dump</> now supports multiple <literal>-n</>
4200 (schema) and <literal>-t</> (table) options, and adds
4201 <literal>-N</> and <literal>-T</> options to exclude objects.
4202 Also, the arguments of these switches can now be wild-card expressions
4203 rather than single object names, for example
4204 <literal>-t 'foo*'</>, and a schema can be part of
4205 a <literal>-t</> or <literal>-T</> switch, for example
4206 <literal>-t schema1.table1</>.
4207 </para>
4208 </listitem>
4210 <listitem>
4211 <para>
4212 Add <link linkend="APP-PGRESTORE"><application>pg_restore</></link>
4213 <literal>--no-data-for-failed-tables</> option to suppress
4214 loading data if table creation failed (i.e., the table already
4215 exists) (Martin Pitt)
4216 </para>
4217 </listitem>
4219 <listitem>
4220 <para>
4221 Add <link linkend="APP-PGRESTORE"><application>pg_restore</></link>
4222 option to run the entire session in a single transaction
4223 (Simon)
4224 </para>
4226 <para>
4227 Use option <literal>-1</> or <literal>--single-transaction</>.
4228 </para>
4229 </listitem>
4231 </itemizedlist>
4233 </sect3>
4235 <sect3>
4236 <title><link linkend="libpq"><application>libpq</></link> Changes</title>
4237 <itemizedlist>
4239 <listitem>
4240 <para>
4241 Add <link
4242 linkend="libpq-misc"><function>PQencryptPassword()</></link>
4243 to encrypt passwords (Tom)
4244 </para>
4246 <para>
4247 This allows passwords to be sent pre-encrypted for commands
4248 like <link linkend="SQL-ALTERROLE"><command>ALTER ROLE ...
4249 PASSWORD</></link>.
4250 </para>
4251 </listitem>
4253 <listitem>
4254 <para>
4255 Add function <link
4256 linkend="libpq-threading"><function>PQisthreadsafe()</></link>
4257 (Bruce)
4258 </para>
4260 <para>
4261 This allows applications to query the thread-safety status
4262 of the library.
4263 </para>
4264 </listitem>
4266 <listitem>
4267 <para>
4268 Add <link
4269 linkend="libpq-exec-main"><function>PQdescribePrepared()</></link>,
4270 <link
4271 linkend="libpq-exec-main"><function>PQdescribePortal()</></link>,
4272 and related functions to return information about previously
4273 prepared statements and open cursors (Volkan YAZICI)
4274 </para>
4275 </listitem>
4277 <listitem>
4278 <para>
4279 Allow <link linkend="libpq-ldap"><acronym>LDAP</></link> lookups
4280 from <link
4281 linkend="libpq-pgservice"><filename>pg_service.conf</></link>
4282 (Laurenz Albe)
4283 </para>
4284 </listitem>
4286 <listitem>
4287 <para>
4288 Allow a hostname in <link
4289 linkend="libpq-pgpass"><filename>~/.pgpass</></link>
4290 to match the default socket directory (Bruce)
4291 </para>
4293 <para>
4294 A blank hostname continues to match any Unix-socket connection,
4295 but this addition allows entries that are specific to one of
4296 several postmasters on the machine.
4297 </para>
4298 </listitem>
4300 </itemizedlist>
4302 </sect3>
4304 <sect3>
4305 <title><link linkend="ecpg"><application>ecpg</></link> Changes</title>
4306 <itemizedlist>
4308 <listitem>
4309 <para>
4310 Allow <link linkend="SQL-SHOW"><command>SHOW</></link> to
4311 put its result into a variable (Joachim Wieland)
4312 </para>
4313 </listitem>
4315 <listitem>
4316 <para>
4317 Add <link linkend="SQL-COPY"><command>COPY TO STDOUT</></link>
4318 (Joachim Wieland)
4319 </para>
4320 </listitem>
4322 <listitem>
4323 <para>
4324 Add regression tests (Joachim Wieland, Michael)
4325 </para>
4326 </listitem>
4328 <listitem>
4329 <para>
4330 Major source code cleanups (Joachim Wieland, Michael)
4331 </para>
4332 </listitem>
4334 </itemizedlist>
4336 </sect3>
4338 <sect3>
4339 <title><application>Windows</> Port</title>
4340 <itemizedlist>
4342 <listitem>
4343 <para>
4344 Allow <acronym>MSVC</> to compile the <productname>PostgreSQL</>
4345 server (Magnus, Hiroshi Saito)
4346 </para>
4347 </listitem>
4349 <listitem>
4350 <para>
4351 Add <acronym>MSVC</> support for utility commands and <link
4352 linkend="APP-PGDUMP"><application>pg_dump</></link> (Hiroshi
4353 Saito)
4354 </para>
4355 </listitem>
4357 <listitem>
4358 <para>
4359 Add support for Windows code pages <literal>1253</>,
4360 <literal>1254</>, <literal>1255</>, and <literal>1257</>
4361 (Kris Jurka)
4362 </para>
4363 </listitem>
4365 <listitem>
4366 <para>
4367 Drop privileges on startup, so that the server can be started from
4368 an administrative account (Magnus)
4369 </para>
4370 </listitem>
4372 <listitem>
4373 <para>
4374 Stability fixes (Qingqing Zhou, Magnus)
4375 </para>
4376 </listitem>
4378 <listitem>
4379 <para>
4380 Add native semaphore implementation (Qingqing Zhou)
4381 </para>
4383 <para>
4384 The previous code mimicked SysV semaphores.
4385 </para>
4386 </listitem>
4388 </itemizedlist>
4390 </sect3>
4392 <sect3>
4393 <title>Source Code Changes</title>
4394 <itemizedlist>
4396 <listitem>
4397 <para>
4398 Add <link linkend="GIN"><acronym>GIN</></link> (Generalized
4399 Inverted iNdex) index access method (Teodor, Oleg)
4400 </para>
4401 </listitem>
4403 <listitem>
4404 <para>
4405 Remove R-tree indexing (Tom)
4406 </para>
4408 <para>
4409 Rtree has been re-implemented using <link
4410 linkend="GiST"><acronym>GiST</></link>. Among other
4411 differences, this means that rtree indexes now have support
4412 for crash recovery via write-ahead logging (WAL).
4413 </para>
4414 </listitem>
4416 <listitem>
4417 <para>
4418 Reduce libraries needlessly linked into the backend (Martijn
4419 van Oosterhout, Tom)
4420 </para>
4421 </listitem>
4423 <listitem>
4424 <para>
4425 Add a configure flag to allow libedit to be preferred over
4426 <acronym>GNU</> readline (Bruce)
4427 </para>
4429 <para>
4430 Use configure <link
4431 linkend="configure"><literal>--with-libedit-preferred</></link>.
4432 </para>
4433 </listitem>
4435 <listitem>
4436 <para>
4437 Allow installation into directories containing spaces
4438 (Peter)
4439 </para>
4440 </listitem>
4442 <listitem>
4443 <para>
4444 Improve ability to relocate installation directories (Tom)
4445 </para>
4446 </listitem>
4448 <listitem>
4449 <para>
4450 Add support for <productname>Solaris x86_64</> using the
4451 <productname>Solaris</> compiler (Pierre Girard, Theo
4452 Schlossnagle, Bruce)
4453 </para>
4454 </listitem>
4456 <listitem>
4457 <para>
4458 Add <application>DTrace</> support (Robert Lor)
4459 </para>
4460 </listitem>
4462 <listitem>
4463 <para>
4464 Add <literal>PG_VERSION_NUM</> for use by third-party
4465 applications wanting to test the backend version in C using &gt;
4466 and &lt; comparisons (Bruce)
4467 </para>
4468 </listitem>
4470 <listitem>
4471 <para>
4472 Add <literal>XLOG_BLCKSZ</> as independent from <literal>BLCKSZ</>
4473 (Mark Wong)
4474 </para>
4475 </listitem>
4477 <listitem>
4478 <para>
4479 Add <literal>LWLOCK_STATS</> define to report locking
4480 activity (Tom)
4481 </para>
4482 </listitem>
4484 <listitem>
4485 <para>
4486 Emit warnings for unknown <application>configure</> options
4487 (Martijn van Oosterhout)
4488 </para>
4489 </listitem>
4491 <listitem>
4492 <para>
4493 Add server support for <quote>plugin</> libraries
4494 that can be used for add-on tasks such as debugging and performance
4495 measurement (Korry Douglas)
4496 </para>
4498 <para>
4499 This consists of two features: a table of <quote>rendezvous
4500 variables</> that allows separately-loaded shared libraries to
4501 communicate, and a new configuration parameter <link
4502 linkend="guc-local-preload-libraries"><varname>local_preload_libraries</></link>
4503 that allows libraries to be loaded into specific sessions without
4504 explicit cooperation from the client application. This allows
4505 external add-ons to implement features such as a PL/PgSQL debugger.
4506 </para>
4507 </listitem>
4509 <listitem>
4510 <para>
4511 Rename existing configuration parameter
4512 <varname>preload_libraries</> to <link
4513 linkend="guc-shared-preload-libraries"><varname>shared_preload_libraries</></link>
4514 (Tom)
4515 </para>
4517 <para>
4518 This was done for clarity in comparison to
4519 <varname>local_preload_libraries</>.
4520 </para>
4521 </listitem>
4523 <listitem>
4524 <para>
4525 Add new configuration parameter <link
4526 linkend="guc-server-version-num"><varname>server_version_num</></link>
4527 (Greg Sabino Mullane)
4528 </para>
4530 <para>
4531 This is like <varname>server_version</varname>, but is an
4532 integer, e.g. <literal>80200</>. This allows applications to
4533 make version checks more easily.
4534 </para>
4535 </listitem>
4537 <listitem>
4538 <para>
4539 Add a configuration parameter <link
4540 linkend="guc-seq-page-cost"><varname>seq_page_cost</></link>
4541 (Tom)
4542 </para>
4543 </listitem>
4545 <listitem>
4546 <para>
4547 Re-implement the <link linkend="regress">regression test</link> script as a C program
4548 (Magnus, Tom)
4549 </para>
4550 </listitem>
4552 <listitem>
4553 <para>
4554 Allow loadable modules to allocate shared memory and
4555 lightweight locks (Marc Munro)
4556 </para>
4557 </listitem>
4559 <listitem>
4560 <para>
4561 Add automatic initialization and finalization of dynamically
4562 loaded libraries (Ralf Engelschall, Tom)
4563 </para>
4565 <para>
4566 New <link linkend="xfunc-c-dynload">functions</link>
4567 <function>_PG_init()</> and <function>_PG_fini()</> are
4568 called if the library defines such symbols. Hence we no
4569 longer need to specify an initialization function in
4570 <varname>shared_preload_libraries</>; we can assume that
4571 the library used the <function>_PG_init()</> convention
4572 instead.
4573 </para>
4574 </listitem>
4576 <listitem>
4577 <para>
4578 Add <link
4579 linkend="xfunc-c-dynload"><literal>PG_MODULE_MAGIC</></link>
4580 header block to all shared object files (Martijn van
4581 Oosterhout)
4582 </para>
4584 <para>
4585 The magic block prevents version mismatches between loadable object
4586 files and servers.
4587 </para>
4588 </listitem>
4590 <listitem>
4591 <para>
4592 Add shared library support for AIX (Laurenz Albe)
4593 </para>
4594 </listitem>
4596 <listitem>
4597 <para>
4598 New <link linkend="datatype-xml"><acronym>XML</></link>
4599 documentation section (Bruce)
4600 </para>
4601 </listitem>
4603 </itemizedlist>
4605 </sect3>
4607 <sect3>
4608 <title>Contrib Changes</title>
4609 <itemizedlist>
4611 <listitem>
4612 <para>
4613 Major tsearch2 improvements (Oleg, Teodor)
4614 </para>
4616 <itemizedlist>
4618 <listitem>
4619 <para>
4620 multibyte encoding support, including <acronym>UTF8</>
4621 </para>
4622 </listitem>
4623 <listitem>
4624 <para>
4625 query rewriting support
4626 </para>
4627 </listitem>
4628 <listitem>
4629 <para>
4630 improved ranking functions
4631 </para>
4632 </listitem>
4633 <listitem>
4634 <para>
4635 thesaurus dictionary support
4636 </para>
4637 </listitem>
4638 <listitem>
4639 <para>
4640 Ispell dictionaries now recognize <application>MySpell</>
4641 format, used by <application>OpenOffice</>
4642 </para>
4643 </listitem>
4644 <listitem>
4645 <para>
4646 <acronym>GIN</> support
4647 </para>
4648 </listitem>
4650 </itemizedlist>
4652 </listitem>
4654 <listitem>
4655 <para>
4656 Add adminpack module containing <application>Pgadmin</> administration
4657 functions (Dave)
4658 </para>
4660 <para>
4661 These functions provide additional file system access
4662 routines not present in the default <productname>PostgreSQL</>
4663 server.
4664 </para>
4665 </listitem>
4667 <listitem>
4668 <para>
4669 Add sslinfo module (Victor Wagner)
4670 </para>
4672 <para>
4673 Reports information about the current connection's <acronym>SSL</>
4674 certificate.
4675 </para>
4676 </listitem>
4678 <listitem>
4679 <para>
4680 Add pgrowlocks module (Tatsuo)
4681 </para>
4683 <para>
4684 This shows row locking information for a specified table.
4685 </para>
4686 </listitem>
4688 <listitem>
4689 <para>
4690 Add hstore module (Oleg, Teodor)
4691 </para>
4692 </listitem>
4694 <listitem>
4695 <para>
4696 Add isn module, replacing isbn_issn (Jeremy Kronuz)
4697 </para>
4699 <para>
4700 This new implementation supports <acronym>EAN13</>, <acronym>UPC</>,
4701 <acronym>ISBN</> (books), <acronym>ISMN</> (music), and
4702 <acronym>ISSN</> (serials).
4703 </para>
4704 </listitem>
4706 <listitem>
4707 <para>
4708 Add index information functions to pgstattuple (ITAGAKI Takahiro,
4709 Satoshi Nagayasu)
4710 </para>
4711 </listitem>
4713 <listitem>
4714 <para>
4715 Add pg_freespacemap module to display free space map information
4716 (Mark Kirkwood)
4717 </para>
4718 </listitem>
4720 <listitem>
4721 <para>
4722 pgcrypto now has all planned functionality (Marko Kreen)
4723 </para>
4724 <itemizedlist>
4725 <listitem>
4726 <para>
4727 Include iMath library in pgcrypto to have the public-key encryption
4728 functions always available.
4729 </para>
4730 </listitem>
4731 <listitem>
4732 <para>
4733 Add SHA224 algorithm that was missing in OpenBSD code.
4734 </para>
4735 </listitem>
4736 <listitem>
4737 <para>
4738 Activate builtin code for SHA224/256/384/512 hashes on older
4739 OpenSSL to have those algorithms always available.
4740 </para>
4741 </listitem>
4742 <listitem>
4743 <para>
4744 New function gen_random_bytes() that returns cryptographically strong
4745 randomness. Useful for generating encryption keys.
4746 </para>
4747 </listitem>
4748 <listitem>
4749 <para>
4750 Remove digest_exists(), hmac_exists() and cipher_exists() functions.
4751 </para>
4752 </listitem>
4753 </itemizedlist>
4754 </listitem>
4756 <listitem>
4757 <para>
4758 Improvements to cube module (Joshua Reich)
4759 </para>
4761 <para>
4762 New functions are <function>cube(float[])</>,
4763 <function>cube(float[], float[])</>, and
4764 <function>cube_subset(cube, int4[])</>.
4765 </para>
4766 </listitem>
4768 <listitem>
4769 <para>
4770 Add async query capability to dblink (Kai Londenberg,
4771 Joe Conway)
4772 </para>
4773 </listitem>
4775 <listitem>
4776 <para>
4777 New operators for array-subset comparisons (<literal>@&gt;</>,
4778 <literal>&lt;@</>, <literal>&amp;&amp;</>) (Tom)
4779 </para>
4781 <para>
4782 Various contrib packages already had these operators for their
4783 datatypes, but the naming wasn't consistent. We have now added
4784 consistently named array-subset comparison operators to the core code
4785 and all the contrib packages that have such functionality.
4786 (The old names remain available, but are deprecated.)
4787 </para>
4788 </listitem>
4790 <listitem>
4791 <para>
4792 Add uninstall scripts for all contrib packages that have install
4793 scripts (David, Josh Drake)
4794 </para>
4795 </listitem>
4797 </itemizedlist>
4799 </sect3>
4801 </sect2>
4802 </sect1>