1 <!-- doc/src/sgml/release-9.1.sgml -->
2 <!-- See header comment in release.sgml about typical markup -->
4 <sect1 id="release-9-1-10">
5 <title>Release 9.1.10</title>
8 <title>Release Date</title>
9 <simpara>2013-10-10</simpara>
13 This release contains a variety of fixes from 9.1.9.
14 For information about new features in the 9.1 major release, see
15 <xref linkend="release-9-1">.
19 <title>Migration to Version 9.1.10</title>
22 A dump/restore is not required for those running 9.1.X.
26 However, if you are upgrading from a version earlier than 9.1.9,
27 see the release notes for 9.1.9.
33 <title>Changes</title>
39 Prevent corruption of multi-byte characters when attempting to
40 case-fold identifiers (Andrew Dunstan)
44 <productname>PostgreSQL</> case-folds non-ASCII characters only
45 when using a single-byte server encoding.
51 Fix checkpoint memory leak in background writer when <literal>wal_level =
52 hot_standby</> (Naoya Anzai)
58 Fix memory leak caused by <function>lo_open()</function> failure
65 Fix memory overcommit bug when <varname>work_mem</> is using more
66 than 24GB of memory (Stephen Frost)
72 Serializable snapshot fixes (Kevin Grittner, Heikki Linnakangas)
78 Fix deadlock bug in libpq when using SSL (Stephen Frost)
84 Fix possible SSL state corruption in threaded libpq applications
85 (Nick Phillips, Stephen Frost)
91 Properly compute row estimates for boolean columns containing many NULL
92 values (Andrew Gierth)
96 Previously tests like <literal>col IS NOT TRUE</> and <literal>col IS
97 NOT FALSE</> did not properly factor in NULL values when estimating
104 Prevent pushing down <literal>WHERE</> clauses into unsafe
105 <literal>UNION/INTERSECT</> subqueries (Tom Lane)
109 Subqueries of a <literal>UNION</> or <literal>INTERSECT</> that
110 contain set-returning functions or volatile functions in their
111 <literal>SELECT</> lists could be improperly optimized, leading to
112 run-time errors or incorrect query results.
118 Fix rare case of <quote>failed to locate grouping columns</>
119 planner failure (Tom Lane)
125 Fix <application>pg_dump</> of foreign tables with dropped columns (Andrew Dunstan)
129 Previously such cases could cause a <application>pg_upgrade</> error.
135 Reorder <application>pg_dump</> processing of extension-related
136 rules and event triggers (Joe Conway)
142 Force dumping of extension tables if specified by <command>pg_dump
143 -t</> or <literal>-n</> (Joe Conway)
149 Improve view dumping code's handling of dropped columns in referenced
156 Fix <command>pg_restore -l</> with the directory archive to display
157 the correct format name (Fujii Masao)
163 Properly record index comments created using <literal>UNIQUE</>
164 and <literal>PRIMARY KEY</> syntax (Andres Freund)
168 This fixes a parallel <application>pg_restore</> failure.
174 Properly guarantee transmission of WAL files before clean switchover
179 Previously, the streaming replication connection might close before all
180 WAL files had been replayed on the standby.
186 Fix WAL segment timeline handling during recovery (Mitsumasa Kondo,
191 WAL file recycling during standby recovery could lead to premature
192 recovery completion, resulting in data loss.
198 Fix <command>REINDEX TABLE</> and <command>REINDEX DATABASE</>
199 to properly revalidate constraints and mark invalidated indexes as
204 <command>REINDEX INDEX</> has always worked properly.
210 Fix possible deadlock during concurrent <command>CREATE INDEX
211 CONCURRENTLY</> operations (Tom Lane)
217 Fix <function>regexp_matches()</> handling of zero-length matches
222 Previously, zero-length matches like '^' could return too many matches.
228 Fix crash for overly-complex regular expressions (Heikki Linnakangas)
234 Fix regular expression match failures for back references combined with
235 non-greedy quantifiers (Jeevan Chalke)
241 Prevent <command>CREATE FUNCTION</> from checking <command>SET</>
242 variables unless function body checking is enabled (Tom Lane)
248 Allow <command>ALTER DEFAULT PRIVILEGES</> to operate on schemas
249 without requiring CREATE permission (Tom Lane)
255 Loosen restriction on keywords used in queries (Tom Lane)
259 Specifically, lessen keyword restrictions for role names, language
260 names, <command>EXPLAIN</> and <command>COPY</> options, and
261 <command>SET</> values. This allows <literal>COPY ... (FORMAT
262 BINARY)</> to work as expected; previously <literal>BINARY</> needed
269 Fix <function>pgp_pub_decrypt()</> so it works for secret keys with
270 passwords (Marko Kreen)
276 Make <application>pg_upgrade</> use <literal>pg_dump
277 --quote-all-identifiers</> to avoid problems with keyword changes
278 between releases (Tom Lane)
284 Remove rare inaccurate warning during vacuum of index-less tables
291 Ensure that <command>VACUUM ANALYZE</> still runs the ANALYZE phase
292 if its attempt to truncate the file is cancelled due to lock conflicts
299 Avoid possible failure when performing transaction control commands (e.g
300 <command>ROLLBACK</>) in prepared queries (Tom Lane)
306 Ensure that floating-point data input accepts standard spellings
307 of <quote>infinity</> on all platforms (Tom Lane)
311 The C99 standard says that allowable spellings are <literal>inf</>,
312 <literal>+inf</>, <literal>-inf</>, <literal>infinity</>,
313 <literal>+infinity</>, and <literal>-infinity</>. Make sure we
314 recognize these even if the platform's <function>strtod</> function
321 Expand ability to compare rows to records and arrays (Rafal Rzepecki,
328 Update time zone data files to <application>tzdata</> release 2013d
329 for DST law changes in Israel, Morocco, Palestine, and Paraguay.
330 Also, historical zone data corrections for Macquarie Island.
339 <sect1 id="release-9-1-9">
340 <title>Release 9.1.9</title>
343 <title>Release Date</title>
344 <simpara>2013-04-04</simpara>
348 This release contains a variety of fixes from 9.1.8.
349 For information about new features in the 9.1 major release, see
350 <xref linkend="release-9-1">.
354 <title>Migration to Version 9.1.9</title>
357 A dump/restore is not required for those running 9.1.X.
361 However, this release corrects several errors in management of GiST
362 indexes. After installing this update, it is advisable to
363 <command>REINDEX</> any GiST indexes that meet one or more of the
364 conditions described below.
368 Also, if you are upgrading from a version earlier than 9.1.6,
369 see the release notes for 9.1.6.
375 <title>Changes</title>
381 Fix insecure parsing of server command-line switches (Mitsumasa
382 Kondo, Kyotaro Horiguchi)
386 A connection request containing a database name that begins with
387 <quote><literal>-</></quote> could be crafted to damage or destroy
388 files within the server's data directory, even if the request is
389 eventually rejected. (CVE-2013-1899)
395 Reset OpenSSL randomness state in each postmaster child process
400 This avoids a scenario wherein random numbers generated by
401 <filename>contrib/pgcrypto</> functions might be relatively easy for
402 another database user to guess. The risk is only significant when
403 the postmaster is configured with <varname>ssl</> = <literal>on</>
404 but most connections don't use SSL encryption. (CVE-2013-1900)
410 Make REPLICATION privilege checks test current user not authenticated
415 An unprivileged database user could exploit this mistake to call
416 <function>pg_start_backup()</> or <function>pg_stop_backup()</>,
417 thus possibly interfering with creation of routine backups.
424 Fix GiST indexes to not use <quote>fuzzy</> geometric comparisons when
425 it's not appropriate to do so (Alexander Korotkov)
429 The core geometric types perform comparisons using <quote>fuzzy</>
430 equality, but <function>gist_box_same</> must do exact comparisons,
431 else GiST indexes using it might become inconsistent. After installing
432 this update, users should <command>REINDEX</> any GiST indexes on
433 <type>box</>, <type>polygon</>, <type>circle</>, or <type>point</>
434 columns, since all of these use <function>gist_box_same</>.
440 Fix erroneous range-union and penalty logic in GiST indexes that use
441 <filename>contrib/btree_gist</> for variable-width data types, that is
442 <type>text</>, <type>bytea</>, <type>bit</>, and <type>numeric</>
447 These errors could result in inconsistent indexes in which some keys
448 that are present would not be found by searches, and also in useless
449 index bloat. Users are advised to <command>REINDEX</> such indexes
450 after installing this update.
456 Fix bugs in GiST page splitting code for multi-column indexes
461 These errors could result in inconsistent indexes in which some keys
462 that are present would not be found by searches, and also in indexes
463 that are unnecessarily inefficient to search. Users are advised to
464 <command>REINDEX</> multi-column GiST indexes after installing this
471 Fix <function>gist_point_consistent</>
472 to handle fuzziness consistently (Alexander Korotkov)
476 Index scans on GiST indexes on <type>point</> columns would sometimes
477 yield results different from a sequential scan, because
478 <function>gist_point_consistent</> disagreed with the underlying
479 operator code about whether to do comparisons exactly or fuzzily.
485 Fix buffer leak in WAL replay (Heikki Linnakangas)
489 This bug could result in <quote>incorrect local pin count</> errors
490 during replay, making recovery impossible.
496 Fix race condition in <command>DELETE RETURNING</> (Tom Lane)
500 Under the right circumstances, <command>DELETE RETURNING</> could
501 attempt to fetch data from a shared buffer that the current process
502 no longer has any pin on. If some other process changed the buffer
503 meanwhile, this would lead to garbage <literal>RETURNING</> output, or
510 Fix infinite-loop risk in regular expression compilation (Tom Lane,
517 Fix potential null-pointer dereference in regular expression compilation
524 Fix <function>to_char()</> to use ASCII-only case-folding rules where
525 appropriate (Tom Lane)
529 This fixes misbehavior of some template patterns that should be
530 locale-independent, but mishandled <quote><literal>I</></quote> and
531 <quote><literal>i</></quote> in Turkish locales.
537 Fix unwanted rejection of timestamp <literal>1999-12-31 24:00:00</>
544 Fix logic error when a single transaction does <command>UNLISTEN</>
545 then <command>LISTEN</> (Tom Lane)
549 The session wound up not listening for notify events at all, though it
550 surely should listen in this case.
556 Fix possible planner crash after columns have been added to a view
557 that's depended on by another view (Tom Lane)
563 Remove useless <quote>picksplit doesn't support secondary split</> log
564 messages (Josh Hansen, Tom Lane)
568 This message seems to have been added in expectation of code that was
569 never written, and probably never will be, since GiST's default
570 handling of secondary splits is actually pretty good. So stop nagging
577 Fix possible failure to send a session's last few transaction
578 commit/abort counts to the statistics collector (Tom Lane)
584 Eliminate memory leaks in PL/Perl's <function>spi_prepare()</> function
585 (Alex Hunsaker, Tom Lane)
591 Fix <application>pg_dumpall</> to handle database names containing
592 <quote><literal>=</></quote> correctly (Heikki Linnakangas)
598 Avoid crash in <application>pg_dump</> when an incorrect connection
599 string is given (Heikki Linnakangas)
605 Ignore invalid indexes in <application>pg_dump</> and
606 <application>pg_upgrade</> (Michael Paquier, Bruce Momjian)
610 Dumping invalid indexes can cause problems at restore time, for example
611 if the reason the index creation failed was because it tried to enforce
612 a uniqueness condition not satisfied by the table's data. Also, if the
613 index creation is in fact still in progress, it seems reasonable to
614 consider it to be an uncommitted DDL change, which
615 <application>pg_dump</> wouldn't be expected to dump anyway.
616 <application>pg_upgrade</> now also skips invalid indexes rather than
623 In <application>pg_basebackup</>, include only the current server
624 version's subdirectory when backing up a tablespace (Heikki
631 Add a server version check in <application>pg_basebackup</> and
632 <application>pg_receivexlog</>, so they fail cleanly with version
633 combinations that won't work (Heikki Linnakangas)
639 Fix <filename>contrib/pg_trgm</>'s <function>similarity()</> function
640 to return zero for trigram-less strings (Tom Lane)
644 Previously it returned <literal>NaN</> due to internal division by zero.
650 Update time zone data files to <application>tzdata</> release 2013b
651 for DST law changes in Chile, Haiti, Morocco, Paraguay, and some
652 Russian areas. Also, historical zone data corrections for numerous
657 Also, update the time zone abbreviation files for recent changes in
658 Russia and elsewhere: <literal>CHOT</>, <literal>GET</>,
659 <literal>IRKT</>, <literal>KGT</>, <literal>KRAT</>, <literal>MAGT</>,
660 <literal>MAWT</>, <literal>MSK</>, <literal>NOVT</>, <literal>OMST</>,
661 <literal>TKT</>, <literal>VLAT</>, <literal>WST</>, <literal>YAKT</>,
662 <literal>YEKT</> now follow their current meanings, and
663 <literal>VOLT</> (Europe/Volgograd) and <literal>MIST</>
664 (Antarctica/Macquarie) are added to the default abbreviations list.
673 <sect1 id="release-9-1-8">
674 <title>Release 9.1.8</title>
677 <title>Release Date</title>
678 <simpara>2013-02-07</simpara>
682 This release contains a variety of fixes from 9.1.7.
683 For information about new features in the 9.1 major release, see
684 <xref linkend="release-9-1">.
688 <title>Migration to Version 9.1.8</title>
691 A dump/restore is not required for those running 9.1.X.
695 However, if you are upgrading from a version earlier than 9.1.6,
696 see the release notes for 9.1.6.
702 <title>Changes</title>
708 Prevent execution of <function>enum_recv</> from SQL (Tom Lane)
712 The function was misdeclared, allowing a simple SQL command to crash the
713 server. In principle an attacker might be able to use it to examine the
714 contents of server memory. Our thanks to Sumit Soni (via Secunia SVCRP)
715 for reporting this issue. (CVE-2013-0255)
721 Fix multiple problems in detection of when a consistent database
722 state has been reached during WAL replay (Fujii Masao, Heikki
723 Linnakangas, Simon Riggs, Andres Freund)
729 Update minimum recovery point when truncating a relation file (Heikki
734 Once data has been discarded, it's no longer safe to stop recovery at
735 an earlier point in the timeline.
741 Fix recycling of WAL segments after changing recovery target timeline
748 Fix missing cancellations in hot standby mode (Noah Misch, Simon Riggs)
752 The need to cancel conflicting hot-standby queries would sometimes be
753 missed, allowing those queries to see inconsistent data.
759 Prevent recovery pause feature from pausing before users can connect
766 Fix SQL grammar to allow subscripting or field selection from a
767 sub-SELECT result (Tom Lane)
773 Fix performance problems with autovacuum truncation in busy workloads
778 Truncation of empty pages at the end of a table requires exclusive
779 lock, but autovacuum was coded to fail (and release the table lock)
780 when there are conflicting lock requests. Under load, it is easily
781 possible that truncation would never occur, resulting in table bloat.
782 Fix by performing a partial truncation, releasing the lock, then
783 attempting to re-acquire the lock and continue. This fix also greatly
784 reduces the average time before autovacuum releases the lock after a
785 conflicting request arrives.
791 Protect against race conditions when scanning
792 <structname>pg_tablespace</> (Stephen Frost, Tom Lane)
796 <command>CREATE DATABASE</> and <command>DROP DATABASE</> could
797 misbehave if there were concurrent updates of
798 <structname>pg_tablespace</> entries.
804 Prevent <command>DROP OWNED</> from trying to drop whole databases or
805 tablespaces (Álvaro Herrera)
809 For safety, ownership of these objects must be reassigned, not dropped.
816 linkend="guc-vacuum-freeze-table-age"><varname>vacuum_freeze_table_age</></link>
817 implementation (Andres Freund)
821 In installations that have existed for more than <link
822 linkend="guc-vacuum-freeze-min-age"><varname>vacuum_freeze_min_age</></link>
823 transactions, this mistake prevented autovacuum from using partial-table
824 scans, so that a full-table scan would always happen instead.
830 Prevent misbehavior when a <symbol>RowExpr</> or <symbol>XmlExpr</>
831 is parse-analyzed twice (Andres Freund, Tom Lane)
835 This mistake could be user-visible in contexts such as
836 <literal>CREATE TABLE LIKE INCLUDING INDEXES</>.
842 Improve defenses against integer overflow in hashtable sizing
843 calculations (Jeff Davis)
849 Fix failure to ignore leftover temporary tables after a server crash
856 Reject out-of-range dates in <function>to_date()</> (Hitoshi Harada)
862 Fix <function>pg_extension_config_dump()</> to handle
863 extension-update cases properly (Tom Lane)
867 This function will now replace any existing entry for the target
868 table, making it usable in extension update scripts.
874 Fix PL/Python's handling of functions used as triggers on multiple
875 tables (Andres Freund)
881 Ensure that non-ASCII prompt strings are translated to the correct
882 code page on Windows (Alexander Law, Noah Misch)
886 This bug affected <application>psql</> and some other client programs.
892 Fix possible crash in <application>psql</>'s <command>\?</> command
893 when not connected to a database (Meng Qingzhong)
899 Fix possible error if a relation file is removed while
900 <application>pg_basebackup</> is running (Heikki Linnakangas)
906 Make <application>pg_dump</> exclude data of unlogged tables when
907 running on a hot-standby server (Magnus Hagander)
911 This would fail anyway because the data is not available on the standby
912 server, so it seems most convenient to assume
913 <option>--no-unlogged-table-data</> automatically.
919 Fix <application>pg_upgrade</> to deal with invalid indexes safely
926 Fix one-byte buffer overrun in <application>libpq</>'s
927 <function>PQprintTuples</> (Xi Wang)
931 This ancient function is not used anywhere by
932 <productname>PostgreSQL</> itself, but it might still be used by some
939 Make <application>ecpglib</> use translated messages properly
946 Properly install <application>ecpg_compat</> and
947 <application>pgtypes</> libraries on MSVC (Jiang Guiqing)
953 Include our version of <function>isinf()</> in
954 <application>libecpg</> if it's not provided by the system
961 Rearrange configure's tests for supplied functions so it is not
962 fooled by bogus exports from libedit/libreadline (Christoph Berg)
968 Ensure Windows build number increases over time (Magnus Hagander)
974 Make <application>pgxs</> build executables with the right
975 <literal>.exe</> suffix when cross-compiling for Windows
982 Add new timezone abbreviation <literal>FET</> (Tom Lane)
986 This is now used in some eastern-European time zones.
995 <sect1 id="release-9-1-7">
996 <title>Release 9.1.7</title>
999 <title>Release Date</title>
1000 <simpara>2012-12-06</simpara>
1004 This release contains a variety of fixes from 9.1.6.
1005 For information about new features in the 9.1 major release, see
1006 <xref linkend="release-9-1">.
1010 <title>Migration to Version 9.1.7</title>
1013 A dump/restore is not required for those running 9.1.X.
1017 However, if you are upgrading from a version earlier than 9.1.6,
1018 see the release notes for 9.1.6.
1024 <title>Changes</title>
1030 Fix multiple bugs associated with <command>CREATE INDEX
1031 CONCURRENTLY</> (Andres Freund, Tom Lane)
1035 Fix <command>CREATE INDEX CONCURRENTLY</> to use
1036 in-place updates when changing the state of an index's
1037 <structname>pg_index</> row. This prevents race conditions that could
1038 cause concurrent sessions to miss updating the target index, thus
1039 resulting in corrupt concurrently-created indexes.
1043 Also, fix various other operations to ensure that they ignore
1044 invalid indexes resulting from a failed <command>CREATE INDEX
1045 CONCURRENTLY</> command. The most important of these is
1046 <command>VACUUM</>, because an auto-vacuum could easily be launched
1047 on the table before corrective action can be taken to fix or remove
1054 Fix buffer locking during WAL replay (Tom Lane)
1058 The WAL replay code was insufficiently careful about locking buffers
1059 when replaying WAL records that affect more than one page. This could
1060 result in hot standby queries transiently seeing inconsistent states,
1061 resulting in wrong answers or unexpected failures.
1067 Fix an error in WAL generation logic for GIN indexes (Tom Lane)
1071 This could result in index corruption, if a torn-page failure occurred.
1077 Properly remove startup process's virtual XID lock when promoting a
1078 hot standby server to normal running (Simon Riggs)
1082 This oversight could prevent subsequent execution of certain
1083 operations such as <command>CREATE INDEX CONCURRENTLY</>.
1089 Avoid bogus <quote>out-of-sequence timeline ID</> errors in standby
1090 mode (Heikki Linnakangas)
1096 Prevent the postmaster from launching new child processes after it's
1097 received a shutdown signal (Tom Lane)
1101 This mistake could result in shutdown taking longer than it should, or
1102 even never completing at all without additional user action.
1108 Avoid corruption of internal hash tables when out of memory
1115 Prevent file descriptors for dropped tables from being held open past
1116 transaction end (Tom Lane)
1120 This should reduce problems with long-since-dropped tables continuing
1121 to occupy disk space.
1127 Prevent database-wide crash and restart when a new child process is
1128 unable to create a pipe for its latch (Tom Lane)
1132 Although the new process must fail, there is no good reason to force a
1133 database-wide restart, so avoid that. This improves robustness when
1134 the kernel is nearly out of file descriptors.
1140 Fix planning of non-strict equivalence clauses above outer joins
1145 The planner could derive incorrect constraints from a clause equating
1146 a non-strict construct to something else, for example
1147 <literal>WHERE COALESCE(foo, 0) = 0</>
1148 when <literal>foo</> is coming from the nullable side of an outer join.
1154 Fix <command>SELECT DISTINCT</> with index-optimized
1155 <function>MIN</>/<function>MAX</> on an inheritance tree (Tom Lane)
1159 The planner would fail with <quote>failed to re-find MinMaxAggInfo
1160 record</> given this combination of factors.
1166 Improve planner's ability to prove exclusion constraints from
1167 equivalence classes (Tom Lane)
1173 Fix partial-row matching in hashed subplans to handle cross-type cases
1174 correctly (Tom Lane)
1178 This affects multicolumn <literal>NOT IN</> subplans, such as
1179 <literal>WHERE (a, b) NOT IN (SELECT x, y FROM ...)</>
1180 when for instance <literal>b</> and <literal>y</> are <type>int4</>
1181 and <type>int8</> respectively. This mistake led to wrong answers
1182 or crashes depending on the specific datatypes involved.
1188 Acquire buffer lock when re-fetching the old tuple for an
1189 <literal>AFTER ROW UPDATE/DELETE</> trigger (Andres Freund)
1193 In very unusual circumstances, this oversight could result in passing
1194 incorrect data to a trigger <literal>WHEN</> condition, or to the
1195 precheck logic for a foreign-key enforcement trigger. That could
1196 result in a crash, or in an incorrect decision about whether to
1203 Fix <command>ALTER COLUMN TYPE</> to handle inherited check
1204 constraints properly (Pavan Deolasee)
1208 This worked correctly in pre-8.4 releases, and now works correctly
1215 Fix <command>ALTER EXTENSION SET SCHEMA</>'s failure to move some
1216 subsidiary objects into the new schema (Álvaro Herrera, Dimitri
1223 Fix <command>REASSIGN OWNED</> to handle grants on tablespaces
1224 (Álvaro Herrera)
1230 Ignore incorrect <structname>pg_attribute</> entries for system
1231 columns for views (Tom Lane)
1235 Views do not have any system columns. However, we forgot to
1236 remove such entries when converting a table to a view. That's fixed
1237 properly for 9.3 and later, but in previous branches we need to defend
1238 against existing mis-converted views.
1244 Fix rule printing to dump <literal>INSERT INTO <replaceable>table</>
1245 DEFAULT VALUES</literal> correctly (Tom Lane)
1251 Guard against stack overflow when there are too many
1252 <literal>UNION</>/<literal>INTERSECT</>/<literal>EXCEPT</> clauses
1253 in a query (Tom Lane)
1259 Prevent platform-dependent failures when dividing the minimum possible
1260 integer value by -1 (Xi Wang, Tom Lane)
1266 Fix possible access past end of string in date parsing
1273 Fix failure to advance XID epoch if XID wraparound happens during a
1274 checkpoint and <varname>wal_level</> is <literal>hot_standby</>
1275 (Tom Lane, Andres Freund)
1279 While this mistake had no particular impact on
1280 <productname>PostgreSQL</productname> itself, it was bad for
1281 applications that rely on <function>txid_current()</> and related
1282 functions: the TXID value would appear to go backwards.
1289 <structname>pg_stat_replication</>.<structfield>sync_state</> at a
1290 page boundary (Kyotaro Horiguchi)
1296 Produce an understandable error message if the length of the path name
1297 for a Unix-domain socket exceeds the platform-specific limit
1298 (Tom Lane, Andrew Dunstan)
1302 Formerly, this would result in something quite unhelpful, such as
1303 <quote>Non-recoverable failure in name resolution</>.
1309 Fix memory leaks when sending composite column values to the client
1316 Make <application>pg_ctl</> more robust about reading the
1317 <filename>postmaster.pid</> file (Heikki Linnakangas)
1321 Fix race conditions and possible file descriptor leakage.
1327 Fix possible crash in <application>psql</> if incorrectly-encoded data
1328 is presented and the <varname>client_encoding</> setting is a
1329 client-only encoding, such as SJIS (Jiang Guiqing)
1335 Make <application>pg_dump</> dump <literal>SEQUENCE SET</> items in
1336 the data not pre-data section of the archive (Tom Lane)
1340 This change fixes dumping of sequences that are marked as extension
1341 configuration tables.
1347 Fix bugs in the <filename>restore.sql</> script emitted by
1348 <application>pg_dump</> in <literal>tar</> output format (Tom Lane)
1352 The script would fail outright on tables whose names include
1353 upper-case characters. Also, make the script capable of restoring
1354 data in <option>--inserts</> mode as well as the regular COPY mode.
1360 Fix <application>pg_restore</> to accept POSIX-conformant
1361 <literal>tar</> files (Brian Weaver, Tom Lane)
1365 The original coding of <application>pg_dump</>'s <literal>tar</>
1366 output mode produced files that are not fully conformant with the
1367 POSIX standard. This has been corrected for version 9.3. This
1368 patch updates previous branches so that they will accept both the
1369 incorrect and the corrected formats, in hopes of avoiding
1370 compatibility problems when 9.3 comes out.
1376 Fix <literal>tar</> files emitted by <application>pg_basebackup</> to
1377 be POSIX conformant (Brian Weaver, Tom Lane)
1383 Fix <application>pg_resetxlog</> to locate <filename>postmaster.pid</>
1384 correctly when given a relative path to the data directory (Tom Lane)
1388 This mistake could lead to <application>pg_resetxlog</> not noticing
1389 that there is an active postmaster using the data directory.
1395 Fix <application>libpq</>'s <function>lo_import()</> and
1396 <function>lo_export()</> functions to report file I/O errors properly
1403 Fix <application>ecpg</>'s processing of nested structure pointer
1404 variables (Muhammad Usama)
1410 Fix <application>ecpg</>'s <function>ecpg_get_data</> function to
1411 handle arrays properly (Michael Meskes)
1417 Make <filename>contrib/pageinspect</>'s btree page inspection
1418 functions take buffer locks while examining pages (Tom Lane)
1424 Ensure that <literal>make install</> for an extension creates the
1425 <filename>extension</> installation directory (Cédric Villemain)
1429 Previously, this step was missed if <varname>MODULEDIR</> was set in
1430 the extension's Makefile.
1436 Fix <application>pgxs</> support for building loadable modules on AIX
1441 Building modules outside the original source tree didn't work on AIX.
1447 Update time zone data files to <application>tzdata</> release 2012j
1448 for DST law changes in Cuba, Israel, Jordan, Libya, Palestine, Western
1449 Samoa, and portions of Brazil.
1458 <sect1 id="release-9-1-6">
1459 <title>Release 9.1.6</title>
1462 <title>Release Date</title>
1463 <simpara>2012-09-24</simpara>
1467 This release contains a variety of fixes from 9.1.5.
1468 For information about new features in the 9.1 major release, see
1469 <xref linkend="release-9-1">.
1473 <title>Migration to Version 9.1.6</title>
1476 A dump/restore is not required for those running 9.1.X.
1480 However, you may need to perform <command>REINDEX</> operations to
1481 recover from the effects of the data corruption bug described in the
1482 first changelog item below.
1486 Also, if you are upgrading from a version earlier than 9.1.4,
1487 see the release notes for 9.1.4.
1493 <title>Changes</title>
1499 Fix persistence marking of shared buffers during WAL replay
1504 This mistake can result in buffers not being written out during
1505 checkpoints, resulting in data corruption if the server later crashes
1506 without ever having written those buffers. Corruption can occur on
1507 any server following crash recovery, but it is significantly more
1508 likely to occur on standby slave servers since those perform much
1509 more WAL replay. There is a low probability of corruption of btree
1510 and GIN indexes. There is a much higher probability of corruption of
1511 table <quote>visibility maps</>. Fortunately, visibility maps are
1512 non-critical data in 9.1, so the worst consequence of such corruption
1513 in 9.1 installations is transient inefficiency of vacuuming. Table
1514 data proper cannot be corrupted by this bug.
1518 While no index corruption due to this bug is known to have occurred
1519 in the field, as a precautionary measure it is recommended that
1520 production installations <command>REINDEX</> all btree and GIN
1521 indexes at a convenient time after upgrading to 9.1.6.
1525 Also, if you intend to do an in-place upgrade to 9.2.X, before doing
1526 so it is recommended to perform a <command>VACUUM</> of all tables
1528 linkend="guc-vacuum-freeze-table-age"><varname>vacuum_freeze_table_age</></link>
1529 set to zero. This will ensure that any lingering wrong data in the
1530 visibility maps is corrected before 9.2.X can depend on it. <link
1531 linkend="guc-vacuum-cost-delay"><varname>vacuum_cost_delay</></link>
1532 can be adjusted to reduce the performance impact of vacuuming, while
1533 causing it to take longer to finish.
1539 Fix planner's assignment of executor parameters, and fix executor's
1540 rescan logic for CTE plan nodes (Tom Lane)
1544 These errors could result in wrong answers from queries that scan the
1545 same <literal>WITH</> subquery multiple times.
1551 Fix misbehavior when <link
1552 linkend="guc-default-transaction-isolation"><varname>default_transaction_isolation</></link>
1553 is set to <literal>serializable</> (Kevin Grittner, Tom Lane, Heikki
1558 Symptoms include crashes at process start on Windows, and crashes in
1559 hot standby operation.
1565 Improve selectivity estimation for text search queries involving
1566 prefixes, i.e. <replaceable>word</><literal>:*</> patterns (Tom Lane)
1575 Improve page-splitting decisions in GiST indexes (Alexander Korotkov,
1576 Robert Haas, Tom Lane)
1580 Multi-column GiST indexes might suffer unexpected bloat due to this
1587 Fix cascading privilege revoke to stop if privileges are still held
1592 If we revoke a grant option from some role <replaceable>X</>, but
1593 <replaceable>X</> still holds that option via a grant from someone
1594 else, we should not recursively revoke the corresponding privilege
1595 from role(s) <replaceable>Y</> that <replaceable>X</> had granted it
1602 Disallow extensions from containing the schema they are assigned to
1607 This situation creates circular dependencies that confuse
1608 <application>pg_dump</> and probably other things. It's confusing
1609 for humans too, so disallow it.
1615 Improve error messages for Hot Standby misconfiguration errors
1622 Make <application>configure</> probe for <function>mbstowcs_l</> (Tom
1627 This fixes build failures on some versions of AIX.
1633 Fix handling of <literal>SIGFPE</> when PL/Perl is in use (Andres Freund)
1637 Perl resets the process's <literal>SIGFPE</> handler to
1638 <literal>SIG_IGN</>, which could result in crashes later on. Restore
1639 the normal Postgres signal handler after initializing PL/Perl.
1645 Prevent PL/Perl from crashing if a recursive PL/Perl function is
1646 redefined while being executed (Tom Lane)
1652 Work around possible misoptimization in PL/Perl (Tom Lane)
1656 Some Linux distributions contain an incorrect version of
1657 <filename>pthread.h</> that results in incorrect compiled code in
1658 PL/Perl, leading to crashes if a PL/Perl function calls another one
1659 that throws an error.
1665 Fix bugs in <filename>contrib/pg_trgm</>'s <literal>LIKE</> pattern
1666 analysis code (Fujii Masao)
1670 <literal>LIKE</> queries using a trigram index could produce wrong
1671 results if the pattern contained <literal>LIKE</> escape characters.
1677 Fix <application>pg_upgrade</>'s handling of line endings on Windows
1682 Previously, <application>pg_upgrade</> might add or remove carriage
1683 returns in places such as function bodies.
1689 On Windows, make <application>pg_upgrade</> use backslash path
1690 separators in the scripts it emits (Andrew Dunstan)
1696 Remove unnecessary dependency on <application>pg_config</> from
1697 <application>pg_upgrade</> (Peter Eisentraut)
1703 Update time zone data files to <application>tzdata</> release 2012f
1704 for DST law changes in Fiji
1713 <sect1 id="release-9-1-5">
1714 <title>Release 9.1.5</title>
1717 <title>Release Date</title>
1718 <simpara>2012-08-17</simpara>
1722 This release contains a variety of fixes from 9.1.4.
1723 For information about new features in the 9.1 major release, see
1724 <xref linkend="release-9-1">.
1728 <title>Migration to Version 9.1.5</title>
1731 A dump/restore is not required for those running 9.1.X.
1735 However, if you are upgrading from a version earlier than 9.1.4,
1736 see the release notes for 9.1.4.
1742 <title>Changes</title>
1748 Prevent access to external files/URLs via XML entity references
1749 (Noah Misch, Tom Lane)
1753 <function>xml_parse()</> would attempt to fetch external files or
1754 URLs as needed to resolve DTD and entity references in an XML value,
1755 thus allowing unprivileged database users to attempt to fetch data
1756 with the privileges of the database server. While the external data
1757 wouldn't get returned directly to the user, portions of it could be
1758 exposed in error messages if the data didn't parse as valid XML; and
1759 in any case the mere ability to check existence of a file might be
1760 useful to an attacker. (CVE-2012-3489)
1766 Prevent access to external files/URLs via <filename>contrib/xml2</>'s
1767 <function>xslt_process()</> (Peter Eisentraut)
1771 <application>libxslt</> offers the ability to read and write both
1772 files and URLs through stylesheet commands, thus allowing
1773 unprivileged database users to both read and write data with the
1774 privileges of the database server. Disable that through proper use
1775 of <application>libxslt</>'s security options. (CVE-2012-3488)
1779 Also, remove <function>xslt_process()</>'s ability to fetch documents
1780 and stylesheets from external files/URLs. While this was a
1781 documented <quote>feature</>, it was long regarded as a bad idea.
1782 The fix for CVE-2012-3489 broke that capability, and rather than
1783 expend effort on trying to fix it, we're just going to summarily
1790 Prevent too-early recycling of btree index pages (Noah Misch)
1794 When we allowed read-only transactions to skip assigning XIDs, we
1795 introduced the possibility that a deleted btree page could be
1796 recycled while a read-only transaction was still in flight to it.
1797 This would result in incorrect index search results. The probability
1798 of such an error occurring in the field seems very low because of the
1799 timing requirements, but nonetheless it should be fixed.
1805 Fix crash-safety bug with newly-created-or-reset sequences (Tom Lane)
1809 If <command>ALTER SEQUENCE</> was executed on a freshly created or
1810 reset sequence, and then precisely one <function>nextval()</> call
1811 was made on it, and then the server crashed, WAL replay would restore
1812 the sequence to a state in which it appeared that no
1813 <function>nextval()</> had been done, thus allowing the first
1814 sequence value to be returned again by the next
1815 <function>nextval()</> call. In particular this could manifest for
1816 <type>serial</> columns, since creation of a serial column's sequence
1817 includes an <command>ALTER SEQUENCE OWNED BY</> step.
1823 Fix race condition in <literal>enum</>-type value comparisons (Robert
1828 Comparisons could fail when encountering an enum value added since
1829 the current query started.
1835 Fix <function>txid_current()</> to report the correct epoch when not
1836 in hot standby (Heikki Linnakangas)
1840 This fixes a regression introduced in the previous minor release.
1846 Prevent selection of unsuitable replication connections as
1847 the synchronous standby (Fujii Masao)
1851 The master might improperly choose pseudo-servers such as
1852 <application>pg_receivexlog</> or <application>pg_basebackup</>
1853 as the synchronous standby, and then wait indefinitely for them.
1859 Fix bug in startup of Hot Standby when a master transaction has many
1860 subtransactions (Andres Freund)
1864 This mistake led to failures reported as <quote>out-of-order XID
1865 insertion in KnownAssignedXids</>.
1871 Ensure the <filename>backup_label</> file is fsync'd after
1872 <function>pg_start_backup()</> (Dave Kerr)
1878 Fix timeout handling in walsender processes (Tom Lane)
1882 WAL sender background processes neglected to establish a
1883 <systemitem>SIGALRM</> handler, meaning they would wait forever in
1884 some corner cases where a timeout ought to happen.
1890 Wake walsenders after each background flush by walwriter (Andres
1891 Freund, Simon Riggs)
1895 This greatly reduces replication delay when the workload contains
1896 only asynchronously-committed transactions.
1902 Fix <literal>LISTEN</>/<literal>NOTIFY</> to cope better with I/O
1903 problems, such as out of disk space (Tom Lane)
1907 After a write failure, all subsequent attempts to send more
1908 <literal>NOTIFY</> messages would fail with messages like
1909 <quote>Could not read from file "pg_notify/<replaceable>nnnn</>" at
1910 offset <replaceable>nnnnn</>: Success</quote>.
1916 Only allow autovacuum to be auto-canceled by a directly blocked
1921 The original coding could allow inconsistent behavior in some cases;
1922 in particular, an autovacuum could get canceled after less than
1923 <literal>deadlock_timeout</> grace period.
1929 Improve logging of autovacuum cancels (Robert Haas)
1935 Fix log collector so that <literal>log_truncate_on_rotation</> works
1936 during the very first log rotation after server start (Tom Lane)
1942 Fix <literal>WITH</> attached to a nested set operation
1943 (<literal>UNION</>/<literal>INTERSECT</>/<literal>EXCEPT</>)
1950 Ensure that a whole-row reference to a subquery doesn't include any
1951 extra <literal>GROUP BY</> or <literal>ORDER BY</> columns (Tom Lane)
1957 Fix dependencies generated during <literal>ALTER TABLE ... ADD
1958 CONSTRAINT USING INDEX</> (Tom Lane)
1962 This command left behind a redundant <structname>pg_depend</> entry
1963 for the index, which could confuse later operations, notably
1964 <literal>ALTER TABLE ... ALTER COLUMN TYPE</> on one of the indexed
1971 Fix <command>REASSIGN OWNED</> to work on extensions (Alvaro Herrera)
1977 Disallow copying whole-row references in <literal>CHECK</>
1978 constraints and index definitions during <command>CREATE TABLE</>
1983 This situation can arise in <command>CREATE TABLE</> with
1984 <literal>LIKE</> or <literal>INHERITS</>. The copied whole-row
1985 variable was incorrectly labeled with the row type of the original
1986 table not the new one. Rejecting the case seems reasonable for
1987 <literal>LIKE</>, since the row types might well diverge later. For
1988 <literal>INHERITS</> we should ideally allow it, with an implicit
1989 coercion to the parent table's row type; but that will require more
1990 work than seems safe to back-patch.
1996 Fix memory leak in <literal>ARRAY(SELECT ...)</> subqueries (Heikki
1997 Linnakangas, Tom Lane)
2003 Fix planner to pass correct collation to operator selectivity
2004 estimators (Tom Lane)
2008 This was not previously required by any core selectivity estimation
2009 function, but third-party code might need it.
2015 Fix extraction of common prefixes from regular expressions (Tom Lane)
2019 The code could get confused by quantified parenthesized
2020 subexpressions, such as <literal>^(foo)?bar</>. This would lead to
2021 incorrect index optimization of searches for such patterns.
2027 Fix bugs with parsing signed
2028 <replaceable>hh</><literal>:</><replaceable>mm</> and
2029 <replaceable>hh</><literal>:</><replaceable>mm</><literal>:</><replaceable>ss</>
2030 fields in <type>interval</> constants (Amit Kapila, Tom Lane)
2036 Fix <application>pg_dump</> to better handle views containing partial
2037 <literal>GROUP BY</> lists (Tom Lane)
2041 A view that lists only a primary key column in <literal>GROUP BY</>,
2042 but uses other table columns as if they were grouped, gets marked as
2043 depending on the primary key. Improper handling of such primary key
2044 dependencies in <application>pg_dump</> resulted in poorly-ordered
2045 dumps, which at best would be inefficient to restore and at worst
2046 could result in outright failure of a parallel
2047 <application>pg_restore</> run.
2053 In PL/Perl, avoid setting UTF8 flag when in SQL_ASCII encoding
2054 (Alex Hunsaker, Kyotaro Horiguchi, Alvaro Herrera)
2060 Use Postgres' encoding conversion functions, not Python's, when
2061 converting a Python Unicode string to the server encoding in
2062 PL/Python (Jan Urbanski)
2066 This avoids some corner-case problems, notably that Python doesn't
2067 support all the encodings Postgres does. A notable functional change
2068 is that if the server encoding is SQL_ASCII, you will get the UTF-8
2069 representation of the string; formerly, any non-ASCII characters in
2070 the string would result in an error.
2076 Fix mapping of PostgreSQL encodings to Python encodings in PL/Python
2083 Report errors properly in <filename>contrib/xml2</>'s
2084 <function>xslt_process()</> (Tom Lane)
2090 Update time zone data files to <application>tzdata</> release 2012e
2091 for DST law changes in Morocco and Tokelau
2100 <sect1 id="release-9-1-4">
2101 <title>Release 9.1.4</title>
2104 <title>Release Date</title>
2105 <simpara>2012-06-04</simpara>
2109 This release contains a variety of fixes from 9.1.3.
2110 For information about new features in the 9.1 major release, see
2111 <xref linkend="release-9-1">.
2115 <title>Migration to Version 9.1.4</title>
2118 A dump/restore is not required for those running 9.1.X.
2122 However, if you use the <type>citext</> data type, and you upgraded
2123 from a previous major release by running <application>pg_upgrade</>,
2124 you should run <literal>CREATE EXTENSION citext FROM unpackaged</>
2125 to avoid collation-related failures in <type>citext</> operations.
2126 The same is necessary if you restore a dump from a pre-9.1 database
2127 that contains an instance of the <type>citext</> data type.
2128 If you've already run the <command>CREATE EXTENSION</> command before
2129 upgrading to 9.1.4, you will instead need to do manual catalog updates
2130 as explained in the third changelog item below.
2134 Also, if you are upgrading from a version earlier than 9.1.2,
2135 see the release notes for 9.1.2.
2141 <title>Changes</title>
2147 Fix incorrect password transformation in
2148 <filename>contrib/pgcrypto</>'s DES <function>crypt()</> function
2153 If a password string contained the byte value <literal>0x80</>, the
2154 remainder of the password was ignored, causing the password to be much
2155 weaker than it appeared. With this fix, the rest of the string is
2156 properly included in the DES hash. Any stored password values that are
2157 affected by this bug will thus no longer match, so the stored values may
2158 need to be updated. (CVE-2012-2143)
2164 Ignore <literal>SECURITY DEFINER</> and <literal>SET</> attributes for
2165 a procedural language's call handler (Tom Lane)
2169 Applying such attributes to a call handler could crash the server.
2176 Make <filename>contrib/citext</>'s upgrade script fix collations of
2177 <type>citext</> arrays and domains over <type>citext</>
2182 Release 9.1.2 provided a fix for collations of <type>citext</> columns
2183 and indexes in databases upgraded or reloaded from pre-9.1
2184 installations, but that fix was incomplete: it neglected to handle arrays
2185 and domains over <type>citext</>. This release extends the module's
2186 upgrade script to handle these cases. As before, if you have already
2187 run the upgrade script, you'll need to run the collation update
2188 commands by hand instead. See the 9.1.2 release notes for more
2189 information about doing this.
2195 Allow numeric timezone offsets in <type>timestamp</> input to be up to
2196 16 hours away from UTC (Tom Lane)
2200 Some historical time zones have offsets larger than 15 hours, the
2201 previous limit. This could result in dumped data values being rejected
2208 Fix timestamp conversion to cope when the given time is exactly the
2209 last DST transition time for the current timezone (Tom Lane)
2213 This oversight has been there a long time, but was not noticed
2214 previously because most DST-using zones are presumed to have an
2215 indefinite sequence of future DST transitions.
2221 Fix <type>text</> to <type>name</> and <type>char</> to <type>name</>
2222 casts to perform string truncation correctly in multibyte encodings
2229 Fix memory copying bug in <function>to_tsquery()</> (Heikki Linnakangas)
2235 Ensure <function>txid_current()</> reports the correct epoch when
2236 executed in hot standby (Simon Riggs)
2242 Fix planner's handling of outer PlaceHolderVars within subqueries (Tom
2247 This bug concerns sub-SELECTs that reference variables coming from the
2248 nullable side of an outer join of the surrounding query.
2249 In 9.1, queries affected by this bug would fail with <quote>ERROR:
2250 Upper-level PlaceHolderVar found where not expected</>. But in 9.0 and
2251 8.4, you'd silently get possibly-wrong answers, since the value
2252 transmitted into the subquery wouldn't go to null when it should.
2258 Fix planning of <literal>UNION ALL</> subqueries with output columns
2259 that are not simple variables (Tom Lane)
2263 Planning of such cases got noticeably worse in 9.1 as a result of a
2264 misguided fix for <quote>MergeAppend child's targetlist doesn't match
2265 MergeAppend</> errors. Revert that fix and do it another way.
2271 Fix slow session startup when <structname>pg_attribute</> is very large
2276 If <structname>pg_attribute</> exceeds one-fourth of
2277 <varname>shared_buffers</>, cache rebuilding code that is sometimes
2278 needed during session start would trigger the synchronized-scan logic,
2279 causing it to take many times longer than normal. The problem was
2280 particularly acute if many new sessions were starting at once.
2286 Ensure sequential scans check for query cancel reasonably often (Merlin
2291 A scan encountering many consecutive pages that contain no live tuples
2292 would not respond to interrupts meanwhile.
2298 Ensure the Windows implementation of <function>PGSemaphoreLock()</>
2299 clears <varname>ImmediateInterruptOK</> before returning (Tom Lane)
2303 This oversight meant that a query-cancel interrupt received later
2304 in the same query could be accepted at an unsafe time, with
2305 unpredictable but not good consequences.
2311 Show whole-row variables safely when printing views or rules
2312 (Abbas Butt, Tom Lane)
2316 Corner cases involving ambiguous names (that is, the name could be
2317 either a table or column name of the query) were printed in an
2318 ambiguous way, risking that the view or rule would be interpreted
2319 differently after dump and reload. Avoid the ambiguous case by
2320 attaching a no-op cast.
2326 Fix <command>COPY FROM</> to properly handle null marker strings that
2327 correspond to invalid encoding (Tom Lane)
2331 A null marker string such as <literal>E'\\0'</> should work, and did
2332 work in the past, but the case got broken in 8.4.
2338 Fix <command>EXPLAIN VERBOSE</> for writable CTEs containing
2339 <literal>RETURNING</> clauses (Tom Lane)
2345 Fix <command>PREPARE TRANSACTION</> to work correctly in the presence
2346 of advisory locks (Tom Lane)
2350 Historically, <command>PREPARE TRANSACTION</> has simply ignored any
2351 session-level advisory locks the session holds, but this case was
2352 accidentally broken in 9.1.
2358 Fix truncation of unlogged tables (Robert Haas)
2364 Ignore missing schemas during non-interactive assignments of
2365 <varname>search_path</> (Tom Lane)
2369 This re-aligns 9.1's behavior with that of older branches. Previously
2370 9.1 would throw an error for nonexistent schemas mentioned in
2371 <varname>search_path</> settings obtained from places such as
2372 <command>ALTER DATABASE SET</>.
2378 Fix bugs with temporary or transient tables used in extension scripts
2383 This includes cases such as a rewriting <command>ALTER TABLE</> within
2384 an extension update script, since that uses a transient table behind
2391 Ensure autovacuum worker processes perform stack depth checking
2392 properly (Heikki Linnakangas)
2396 Previously, infinite recursion in a function invoked by
2397 auto-<command>ANALYZE</> could crash worker processes.
2403 Fix logging collector to not lose log coherency under high load (Andrew
2408 The collector previously could fail to reassemble large messages if it
2415 Fix logging collector to ensure it will restart file rotation
2416 after receiving <systemitem>SIGHUP</> (Tom Lane)
2422 Fix <quote>too many LWLocks taken</> failure in GiST indexes (Heikki
2429 Fix WAL replay logic for GIN indexes to not fail if the index was
2430 subsequently dropped (Tom Lane)
2436 Correctly detect SSI conflicts of prepared transactions after a crash
2443 Avoid synchronous replication delay when committing a transaction that
2444 only modified temporary tables (Heikki Linnakangas)
2448 In such a case the transaction's commit record need not be flushed to
2449 standby servers, but some of the code didn't know that and waited for
2450 it to happen anyway.
2456 Fix error handling in <application>pg_basebackup</>
2457 (Thomas Ogrisegg, Fujii Masao)
2463 Fix <application>walsender</> to not go into a busy loop if connection
2464 is terminated (Fujii Masao)
2470 Fix memory leak in PL/pgSQL's <command>RETURN NEXT</> command (Joe
2477 Fix PL/pgSQL's <command>GET DIAGNOSTICS</> command when the target
2478 is the function's first variable (Tom Lane)
2484 Ensure that PL/Perl package-qualifies the <varname>_TD</> variable
2489 This bug caused trigger invocations to fail when they are nested
2490 within a function invocation that changes the current package.
2496 Fix PL/Python functions returning composite types to accept a string
2497 for their result value (Jan Urbanski)
2501 This case was accidentally broken by the 9.1 additions to allow a
2502 composite result value to be supplied in other formats, such as
2509 Fix potential access off the end of memory in <application>psql</>'s
2510 expanded display (<command>\x</>) mode (Peter Eisentraut)
2516 Fix several performance problems in <application>pg_dump</> when
2517 the database contains many objects (Jeff Janes, Tom Lane)
2521 <application>pg_dump</> could get very slow if the database contained
2522 many schemas, or if many objects are in dependency loops, or if there
2523 are many owned sequences.
2529 Fix memory and file descriptor leaks in <application>pg_restore</>
2530 when reading a directory-format archive (Peter Eisentraut)
2536 Fix <application>pg_upgrade</> for the case that a database stored in a
2537 non-default tablespace contains a table in the cluster's default
2538 tablespace (Bruce Momjian)
2544 In <application>ecpg</>, fix rare memory leaks and possible overwrite
2545 of one byte after the <structname>sqlca_t</> structure (Peter Eisentraut)
2551 Fix <filename>contrib/dblink</>'s <function>dblink_exec()</> to not leak
2552 temporary database connections upon error (Tom Lane)
2558 Fix <filename>contrib/dblink</> to report the correct connection name in
2559 error messages (Kyotaro Horiguchi)
2565 Fix <filename>contrib/vacuumlo</> to use multiple transactions when
2566 dropping many large objects (Tim Lewis, Robert Haas, Tom Lane)
2570 This change avoids exceeding <varname>max_locks_per_transaction</> when
2571 many objects need to be dropped. The behavior can be adjusted with the
2572 new <literal>-l</> (limit) option.
2578 Update time zone data files to <application>tzdata</> release 2012c
2579 for DST law changes in Antarctica, Armenia, Chile, Cuba, Falkland
2580 Islands, Gaza, Haiti, Hebron, Morocco, Syria, and Tokelau Islands;
2581 also historical corrections for Canada.
2590 <sect1 id="release-9-1-3">
2591 <title>Release 9.1.3</title>
2594 <title>Release Date</title>
2595 <simpara>2012-02-27</simpara>
2599 This release contains a variety of fixes from 9.1.2.
2600 For information about new features in the 9.1 major release, see
2601 <xref linkend="release-9-1">.
2605 <title>Migration to Version 9.1.3</title>
2608 A dump/restore is not required for those running 9.1.X.
2612 However, if you are upgrading from a version earlier than 9.1.2,
2613 see the release notes for 9.1.2.
2619 <title>Changes</title>
2625 Require execute permission on the trigger function for
2626 <command>CREATE TRIGGER</> (Robert Haas)
2630 This missing check could allow another user to execute a trigger
2631 function with forged input data, by installing it on a table he owns.
2632 This is only of significance for trigger functions marked
2633 <literal>SECURITY DEFINER</>, since otherwise trigger functions run
2634 as the table owner anyway. (CVE-2012-0866)
2640 Remove arbitrary limitation on length of common name in SSL
2641 certificates (Heikki Linnakangas)
2645 Both <application>libpq</> and the server truncated the common name
2646 extracted from an SSL certificate at 32 bytes. Normally this would
2647 cause nothing worse than an unexpected verification failure, but there
2648 are some rather-implausible scenarios in which it might allow one
2649 certificate holder to impersonate another. The victim would have to
2650 have a common name exactly 32 bytes long, and the attacker would have
2651 to persuade a trusted CA to issue a certificate in which the common
2652 name has that string as a prefix. Impersonating a server would also
2653 require some additional exploit to redirect client connections.
2660 Convert newlines to spaces in names written in <application>pg_dump</>
2661 comments (Robert Haas)
2665 <application>pg_dump</> was incautious about sanitizing object names
2666 that are emitted within SQL comments in its output script. A name
2667 containing a newline would at least render the script syntactically
2668 incorrect. Maliciously crafted object names could present a SQL
2669 injection risk when the script is reloaded. (CVE-2012-0868)
2675 Fix btree index corruption from insertions concurrent with vacuuming
2680 An index page split caused by an insertion could sometimes cause a
2681 concurrently-running <command>VACUUM</> to miss removing index entries
2682 that it should remove. After the corresponding table rows are removed,
2683 the dangling index entries would cause errors (such as <quote>could not
2684 read block N in file ...</>) or worse, silently wrong query results
2685 after unrelated rows are re-inserted at the now-free table locations.
2686 This bug has been present since release 8.2, but occurs so infrequently
2687 that it was not diagnosed until now. If you have reason to suspect
2688 that it has happened in your database, reindexing the affected index
2695 Fix transient zeroing of shared buffers during WAL replay (Tom Lane)
2699 The replay logic would sometimes zero and refill a shared buffer, so
2700 that the contents were transiently invalid. In hot standby mode this
2701 can result in a query that's executing in parallel seeing garbage data.
2702 Various symptoms could result from that, but the most common one seems
2703 to be <quote>invalid memory alloc request size</>.
2709 Fix handling of data-modifying <literal>WITH</> subplans in
2710 <literal>READ COMMITTED</> rechecking (Tom Lane)
2714 A <literal>WITH</> clause containing
2715 <command>INSERT</>/<command>UPDATE</>/<command>DELETE</> would crash
2716 if the parent <command>UPDATE</> or <command>DELETE</> command needed
2717 to be re-evaluated at one or more rows due to concurrent updates
2718 in <literal>READ COMMITTED</> mode.
2724 Fix corner case in SSI transaction cleanup
2729 When finishing up a read-write serializable transaction,
2730 a crash could occur if all remaining active serializable transactions
2737 Fix postmaster to attempt restart after a hot-standby crash (Tom Lane)
2741 A logic error caused the postmaster to terminate, rather than attempt
2742 to restart the cluster, if any backend process crashed while operating
2743 in hot standby mode.
2749 Fix <command>CLUSTER</>/<command>VACUUM FULL</> handling of toast
2750 values owned by recently-updated rows (Tom Lane)
2754 This oversight could lead to <quote>duplicate key value violates unique
2755 constraint</> errors being reported against the toast table's index
2756 during one of these commands.
2762 Update per-column permissions, not only per-table permissions, when
2763 changing table owner (Tom Lane)
2767 Failure to do this meant that any previously granted column permissions
2768 were still shown as having been granted by the old owner. This meant
2769 that neither the new owner nor a superuser could revoke the
2770 now-untraceable-to-table-owner permissions.
2776 Support foreign data wrappers and foreign servers in
2777 <command>REASSIGN OWNED</> (Alvaro Herrera)
2781 This command failed with <quote>unexpected classid</> errors if
2782 it needed to change the ownership of any such objects.
2788 Allow non-existent values for some settings in <command>ALTER
2789 USER/DATABASE SET</> (Heikki Linnakangas)
2793 Allow <varname>default_text_search_config</>,
2794 <varname>default_tablespace</>, and <varname>temp_tablespaces</> to be
2795 set to names that are not known. This is because they might be known
2796 in another database where the setting is intended to be used, or for the
2797 tablespace cases because the tablespace might not be created yet. The
2798 same issue was previously recognized for <varname>search_path</>, and
2799 these settings now act like that one.
2805 Fix <quote>unsupported node type</> error caused by <literal>COLLATE</>
2806 in an <command>INSERT</> expression (Tom Lane)
2812 Avoid crashing when we have problems deleting table files post-commit
2817 Dropping a table should lead to deleting the underlying disk files only
2818 after the transaction commits. In event of failure then (for instance,
2819 because of wrong file permissions) the code is supposed to just emit a
2820 warning message and go on, since it's too late to abort the
2821 transaction. This logic got broken as of release 8.4, causing such
2822 situations to result in a PANIC and an unrestartable database.
2828 Recover from errors occurring during WAL replay of <command>DROP
2829 TABLESPACE</> (Tom Lane)
2833 Replay will attempt to remove the tablespace's directories, but there
2834 are various reasons why this might fail (for example, incorrect
2835 ownership or permissions on those directories). Formerly the replay
2836 code would panic, rendering the database unrestartable without manual
2837 intervention. It seems better to log the problem and continue, since
2838 the only consequence of failure to remove the directories is some
2845 Fix race condition in logging AccessExclusiveLocks for hot standby
2850 Sometimes a lock would be logged as being held by <quote>transaction
2851 zero</>. This is at least known to produce assertion failures on
2852 slave servers, and might be the cause of more serious problems.
2858 Track the OID counter correctly during WAL replay, even when it wraps
2863 Previously the OID counter would remain stuck at a high value until the
2864 system exited replay mode. The practical consequences of that are
2865 usually nil, but there are scenarios wherein a standby server that's
2866 been promoted to master might take a long time to advance the OID
2867 counter to a reasonable value once values are needed.
2873 Prevent emitting misleading <quote>consistent recovery state reached</>
2874 log message at the beginning of crash recovery (Heikki Linnakangas)
2880 Fix initial value of
2881 <structname>pg_stat_replication</>.<structfield>replay_location</>
2886 Previously, the value shown would be wrong until at least one WAL
2887 record had been replayed.
2893 Fix regular expression back-references with <literal>*</> attached
2898 Rather than enforcing an exact string match, the code would effectively
2899 accept any string that satisfies the pattern sub-expression referenced
2900 by the back-reference symbol.
2904 A similar problem still afflicts back-references that are embedded in a
2905 larger quantified expression, rather than being the immediate subject
2906 of the quantifier. This will be addressed in a future
2907 <productname>PostgreSQL</> release.
2913 Fix recently-introduced memory leak in processing of
2914 <type>inet</>/<type>cidr</> values (Heikki Linnakangas)
2918 A patch in the December 2011 releases of <productname>PostgreSQL</>
2919 caused memory leakage in these operations, which could be significant
2920 in scenarios such as building a btree index on such a column.
2926 Fix planner's ability to push down index-expression restrictions
2927 through <literal>UNION ALL</> (Tom Lane)
2931 This type of optimization was inadvertently disabled by a fix for
2932 another problem in 9.1.2.
2938 Fix planning of <literal>WITH</> clauses referenced in
2939 <command>UPDATE</>/<command>DELETE</> on an inherited table
2944 This bug led to <quote>could not find plan for CTE</> failures.
2950 Fix GIN cost estimation to handle <literal>column IN (...)</>
2951 index conditions (Marti Raudsepp)
2955 This oversight would usually lead to crashes if such a condition could
2956 be used with a GIN index.
2962 Prevent assertion failure when exiting a session with an open, failed
2963 transaction (Tom Lane)
2967 This bug has no impact on normal builds with asserts not enabled.
2973 Fix dangling pointer after <command>CREATE TABLE AS</>/<command>SELECT
2974 INTO</> in a SQL-language function (Tom Lane)
2978 In most cases this only led to an assertion failure in assert-enabled
2979 builds, but worse consequences seem possible.
2985 Avoid double close of file handle in syslogger on Windows (MauMau)
2989 Ordinarily this error was invisible, but it would cause an exception
2990 when running on a debug version of Windows.
2996 Fix I/O-conversion-related memory leaks in plpgsql
2997 (Andres Freund, Jan Urbanski, Tom Lane)
3001 Certain operations would leak memory until the end of the current
3008 Work around bug in perl's SvPVutf8() function (Andrew Dunstan)
3012 This function crashes when handed a typeglob or certain read-only
3013 objects such as <literal>$^V</>. Make plperl avoid passing those to
3020 In <application>pg_dump</>, don't dump contents of an extension's
3021 configuration tables if the extension itself is not being dumped
3028 Improve <application>pg_dump</>'s handling of inherited table columns
3033 <application>pg_dump</> mishandled situations where a child column has
3034 a different default expression than its parent column. If the default
3035 is textually identical to the parent's default, but not actually the
3036 same (for instance, because of schema search path differences) it would
3037 not be recognized as different, so that after dump and restore the
3038 child would be allowed to inherit the parent's default. Child columns
3039 that are <literal>NOT NULL</> where their parent is not could also be
3040 restored subtly incorrectly.
3046 Fix <application>pg_restore</>'s direct-to-database mode for
3047 INSERT-style table data (Tom Lane)
3051 Direct-to-database restores from archive files made with
3052 <option>--inserts</> or <option>--column-inserts</> options fail when
3053 using <application>pg_restore</> from a release dated September or
3054 December 2011, as a result of an oversight in a fix for another
3055 problem. The archive file itself is not at fault, and text-mode
3062 Teach <application>pg_upgrade</> to handle renaming of
3063 <application>plpython</>'s shared library (Bruce Momjian)
3067 Upgrading a pre-9.1 database that included plpython would fail because
3074 Allow <application>pg_upgrade</> to process tables containing
3075 <type>regclass</> columns (Bruce Momjian)
3079 Since <application>pg_upgrade</> now takes care to preserve
3080 <structname>pg_class</> OIDs, there was no longer any reason for this
3087 Make <application>libpq</> ignore <literal>ENOTDIR</> errors
3088 when looking for an SSL client certificate file
3093 This allows SSL connections to be established, though without a
3094 certificate, even when the user's home directory is set to something
3095 like <literal>/dev/null</>.
3101 Fix some more field alignment issues in <application>ecpg</>'s SQLDA area
3102 (Zoltan Boszormenyi)
3108 Allow <literal>AT</> option in <application>ecpg</>
3109 <literal>DEALLOCATE</> statements (Michael Meskes)
3113 The infrastructure to support this has been there for awhile, but
3114 through an oversight there was still an error check rejecting the case.
3120 Do not use the variable name when defining a varchar structure in ecpg
3127 Fix <filename>contrib/auto_explain</>'s JSON output mode to produce
3128 valid JSON (Andrew Dunstan)
3132 The output used brackets at the top level, when it should have used
3139 Fix error in <filename>contrib/intarray</>'s <literal>int[] &
3140 int[]</> operator (Guillaume Lelarge)
3144 If the smallest integer the two input arrays have in common is 1,
3145 and there are smaller values in either array, then 1 would be
3146 incorrectly omitted from the result.
3152 Fix error detection in <filename>contrib/pgcrypto</>'s
3153 <function>encrypt_iv()</> and <function>decrypt_iv()</>
3158 These functions failed to report certain types of invalid-input errors,
3159 and would instead return random garbage values for incorrect input.
3165 Fix one-byte buffer overrun in <filename>contrib/test_parser</>
3170 The code would try to read one more byte than it should, which would
3171 crash in corner cases.
3172 Since <filename>contrib/test_parser</> is only example code, this is
3173 not a security issue in itself, but bad example code is still bad.
3179 Use <function>__sync_lock_test_and_set()</> for spinlocks on ARM, if
3180 available (Martin Pitt)
3184 This function replaces our previous use of the <literal>SWPB</>
3185 instruction, which is deprecated and not available on ARMv6 and later.
3186 Reports suggest that the old code doesn't fail in an obvious way on
3187 recent ARM boards, but simply doesn't interlock concurrent accesses,
3188 leading to bizarre failures in multiprocess operation.
3194 Use <option>-fexcess-precision=standard</> option when building with
3195 gcc versions that accept it (Andrew Dunstan)
3199 This prevents assorted scenarios wherein recent versions of gcc will
3200 produce creative results.
3206 Allow use of threaded Python on FreeBSD (Chris Rees)
3210 Our configure script previously believed that this combination wouldn't
3211 work; but FreeBSD fixed the problem, so remove that error check.
3217 Allow MinGW builds to use standardly-named OpenSSL libraries
3227 <sect1 id="release-9-1-2">
3228 <title>Release 9.1.2</title>
3231 <title>Release Date</title>
3232 <simpara>2011-12-05</simpara>
3236 This release contains a variety of fixes from 9.1.1.
3237 For information about new features in the 9.1 major release, see
3238 <xref linkend="release-9-1">.
3242 <title>Migration to Version 9.1.2</title>
3245 A dump/restore is not required for those running 9.1.X.
3249 However, a longstanding error was discovered in the definition of the
3250 <literal>information_schema.referential_constraints</> view. If you
3251 rely on correct results from that view, you should replace its
3252 definition as explained in the first changelog item below.
3256 Also, if you use the <type>citext</> data type, and you upgraded
3257 from a previous major release by running <application>pg_upgrade</>,
3258 you should run <literal>CREATE EXTENSION citext FROM unpackaged</>
3259 to avoid collation-related failures in <type>citext</> operations.
3260 The same is necessary if you restore a dump from a pre-9.1 database
3261 that contains an instance of the <type>citext</> data type.
3262 If you've already run the <command>CREATE EXTENSION</> command before
3263 upgrading to 9.1.2, you will instead need to do manual catalog updates
3264 as explained in the second changelog item.
3270 <title>Changes</title>
3276 Fix bugs in <literal>information_schema.referential_constraints</> view
3281 This view was being insufficiently careful about matching the
3282 foreign-key constraint to the depended-on primary or unique key
3283 constraint. That could result in failure to show a foreign key
3284 constraint at all, or showing it multiple times, or claiming that it
3285 depends on a different constraint than the one it really does.
3289 Since the view definition is installed by <application>initdb</>,
3290 merely upgrading will not fix the problem. If you need to fix this
3291 in an existing installation, you can (as a superuser) drop the
3292 <literal>information_schema</> schema then re-create it by sourcing
3293 <filename><replaceable>SHAREDIR</>/information_schema.sql</filename>.
3294 (Run <literal>pg_config --sharedir</> if you're uncertain where
3295 <replaceable>SHAREDIR</> is.) This must be repeated in each database
3302 Make <filename>contrib/citext</>'s upgrade script fix collations of
3303 <type>citext</> columns and indexes (Tom Lane)
3307 Existing <type>citext</> columns and indexes aren't correctly marked as
3308 being of a collatable data type during <application>pg_upgrade</> from
3309 a pre-9.1 server, or when a pre-9.1 dump containing the <type>citext</>
3310 type is loaded into a 9.1 server.
3311 That leads to operations on these columns failing with errors
3312 such as <quote>could not determine which collation to use for string
3313 comparison</>. This change allows them to be fixed by the same
3314 script that upgrades the <type>citext</> module into a proper 9.1
3315 extension during <literal>CREATE EXTENSION citext FROM unpackaged</>.
3319 If you have a previously-upgraded database that is suffering from this
3320 problem, and you already ran the <command>CREATE EXTENSION</> command,
3321 you can manually run (as superuser) the <command>UPDATE</> commands
3323 <filename><replaceable>SHAREDIR</>/extension/citext--unpackaged--1.0.sql</filename>.
3324 (Run <literal>pg_config --sharedir</> if you're uncertain where
3325 <replaceable>SHAREDIR</> is.)
3326 There is no harm in doing this again if unsure.
3332 Fix possible crash during <command>UPDATE</> or <command>DELETE</> that
3333 joins to the output of a scalar-returning function (Tom Lane)
3337 A crash could only occur if the target row had been concurrently
3338 updated, so this problem surfaced only intermittently.
3344 Fix incorrect replay of WAL records for GIN index updates
3349 This could result in transiently failing to find index entries after
3350 a crash, or on a hot-standby server. The problem would be repaired
3351 by the next <command>VACUUM</> of the index, however.
3357 Fix TOAST-related data corruption during <literal>CREATE TABLE dest AS
3358 SELECT * FROM src</> or <literal>INSERT INTO dest SELECT * FROM src</>
3363 If a table has been modified by <command>ALTER TABLE ADD COLUMN</>,
3364 attempts to copy its data verbatim to another table could produce
3365 corrupt results in certain corner cases.
3366 The problem can only manifest in this precise form in 8.4 and later,
3367 but we patched earlier versions as well in case there are other code
3368 paths that could trigger the same bug.
3374 Fix possible failures during hot standby startup (Simon Riggs)
3380 Start hot standby faster when initial snapshot is incomplete
3387 Fix race condition during toast table access from stale syscache entries
3392 The typical symptom was transient errors like <quote>missing chunk
3393 number 0 for toast value NNNNN in pg_toast_2619</>, where the cited
3394 toast table would always belong to a system catalog.
3400 Track dependencies of functions on items used in parameter default
3401 expressions (Tom Lane)
3405 Previously, a referenced object could be dropped without having dropped
3406 or modified the function, leading to misbehavior when the function was
3407 used. Note that merely installing this update will not fix the missing
3408 dependency entries; to do that, you'd need to <command>CREATE OR
3409 REPLACE</> each such function afterwards. If you have functions whose
3410 defaults depend on non-built-in objects, doing so is recommended.
3416 Fix incorrect management of placeholder variables in nestloop joins
3421 This bug is known to lead to <quote>variable not found in subplan target
3422 list</> planner errors, and could possibly result in wrong query output
3423 when outer joins are involved.
3429 Fix window functions that sort by expressions involving aggregates
3434 Previously these could fail with <quote>could not find pathkey item to
3435 sort</> planner errors.
3441 Fix <quote>MergeAppend child's targetlist doesn't match MergeAppend</>
3442 planner errors (Tom Lane)
3448 Fix index matching for operators with both collatable and noncollatable
3453 In 9.1.0, an indexable operator that has a non-collatable left-hand
3454 input type and a collatable right-hand input type would not be
3455 recognized as matching the left-hand column's index. An example is
3456 the <type>hstore</> <literal>?</> <type>text</> operator.
3462 Allow inlining of set-returning SQL functions with multiple OUT
3463 parameters (Tom Lane)
3469 Don't trust deferred-unique indexes for join removal (Tom Lane and Marti
3474 A deferred uniqueness constraint might not hold intra-transaction,
3475 so assuming that it does could give incorrect query results.
3481 Make <function>DatumGetInetP()</> unpack inet datums that have a 1-byte
3482 header, and add a new macro, <function>DatumGetInetPP()</>, that does
3483 not (Heikki Linnakangas)
3487 This change affects no core code, but might prevent crashes in add-on
3488 code that expects <function>DatumGetInetP()</> to produce an unpacked
3489 datum as per usual convention.
3495 Improve locale support in <type>money</> type's input and output
3500 Aside from not supporting all standard
3501 <link linkend="guc-lc-monetary"><varname>lc_monetary</></link>
3502 formatting options, the input and output functions were inconsistent,
3503 meaning there were locales in which dumped <type>money</> values could
3511 linkend="guc-transform-null-equals"><varname>transform_null_equals</></link>
3512 affect <literal>CASE foo WHEN NULL ...</> constructs
3513 (Heikki Linnakangas)
3517 <varname>transform_null_equals</> is only supposed to affect
3518 <literal>foo = NULL</> expressions written directly by the user, not
3519 equality checks generated internally by this form of <literal>CASE</>.
3525 Change foreign-key trigger creation order to better support
3526 self-referential foreign keys (Tom Lane)
3530 For a cascading foreign key that references its own table, a row update
3531 will fire both the <literal>ON UPDATE</> trigger and the
3532 <literal>CHECK</> trigger as one event. The <literal>ON UPDATE</>
3533 trigger must execute first, else the <literal>CHECK</> will check a
3534 non-final state of the row and possibly throw an inappropriate error.
3535 However, the firing order of these triggers is determined by their
3536 names, which generally sort in creation order since the triggers have
3537 auto-generated names following the convention
3538 <quote>RI_ConstraintTrigger_NNNN</>. A proper fix would require
3539 modifying that convention, which we will do in 9.2, but it seems risky
3540 to change it in existing releases. So this patch just changes the
3541 creation order of the triggers. Users encountering this type of error
3542 should drop and re-create the foreign key constraint to get its
3543 triggers into the right order.
3549 Fix <literal>IF EXISTS</> to work correctly in <command>DROP OPERATOR
3550 FAMILY</> (Robert Haas)
3556 Disallow dropping of an extension from within its own script
3561 This prevents odd behavior in case of incorrect management of extension
3568 Don't mark auto-generated types as extension members (Robert Haas)
3572 Relation rowtypes and automatically-generated array types do not need to
3573 have their own extension membership entries in <structname>pg_depend</>,
3574 and creating such entries complicates matters for extension upgrades.
3580 Cope with invalid pre-existing <varname>search_path</> settings during
3581 <command>CREATE EXTENSION</> (Tom Lane)
3587 Avoid floating-point underflow while tracking buffer allocation rate
3592 While harmless in itself, on certain platforms this would result in
3593 annoying kernel log messages.
3599 Prevent autovacuum transactions from running in serializable mode
3604 Autovacuum formerly used the cluster-wide default transaction isolation
3605 level, but there is no need for it to use anything higher than READ
3606 COMMITTED, and using SERIALIZABLE could result in unnecessary delays
3607 for other processes.
3613 Ensure walsender processes respond promptly to <systemitem>SIGTERM</>
3620 Exclude <filename>postmaster.opts</> from base backups
3627 Preserve configuration file name and line number values when starting
3628 child processes under Windows (Tom Lane)
3632 Formerly, these would not be displayed correctly in the
3633 <structname>pg_settings</> view.
3639 Fix incorrect field alignment in <application>ecpg</>'s SQLDA area
3640 (Zoltan Boszormenyi)
3646 Preserve blank lines within commands in <application>psql</>'s command
3647 history (Robert Haas)
3651 The former behavior could cause problems if an empty line was removed
3652 from within a string literal, for example.
3658 Avoid platform-specific infinite loop in <application>pg_dump</>
3665 Fix compression of plain-text output format in <application>pg_dump</>
3666 (Adrian Klaver and Tom Lane)
3670 <application>pg_dump</> has historically understood <literal>-Z</> with
3671 no <literal>-F</> switch to mean that it should emit a gzip-compressed
3672 version of its plain text output. Restore that behavior.
3678 Fix <application>pg_dump</> to dump user-defined casts between
3679 auto-generated types, such as table rowtypes (Tom Lane)
3685 Fix missed quoting of foreign server names in <application>pg_dump</>
3692 Assorted fixes for <application>pg_upgrade</> (Bruce Momjian)
3696 Handle exclusion constraints correctly, avoid failures on Windows,
3697 don't complain about mismatched toast table names in 8.4 databases.
3703 In PL/pgSQL, allow foreign tables to define row types
3704 (Alexander Soudakov)
3710 Fix up conversions of PL/Perl functions' results
3711 (Alex Hunsaker and Tom Lane)
3715 Restore the pre-9.1 behavior that PL/Perl functions returning
3716 <type>void</> ignore the result value of their last Perl statement;
3717 9.1.0 would throw an error if that statement returned a reference.
3718 Also, make sure it works to return a string value for a composite type,
3719 so long as the string meets the type's input format.
3720 In addition, throw errors for attempts to return Perl arrays or hashes
3721 when the function's declared result type is not an array or composite
3722 type, respectively. (Pre-9.1 versions rather uselessly returned
3723 strings like <literal>ARRAY(0x221a9a0)</> or
3724 <literal>HASH(0x221aa90)</> in such cases.)
3730 Ensure PL/Perl strings are always correctly UTF8-encoded
3731 (Amit Khandekar and Alex Hunsaker)
3737 Use the preferred version of <application>xsubpp</> to build PL/Perl,
3738 not necessarily the operating system's main copy
3739 (David Wheeler and Alex Hunsaker)
3745 Correctly propagate SQLSTATE in PL/Python exceptions
3746 (Mika Eloranta and Jan Urbanski)
3752 Do not install PL/Python extension files for Python major versions
3753 other than the one built against (Peter Eisentraut)
3759 Change all the <filename>contrib</> extension script files to report
3760 a useful error message if they are fed to <application>psql</>
3761 (Andrew Dunstan and Tom Lane)
3765 This should help teach people about the new method of using
3766 <command>CREATE EXTENSION</> to load these files. In most cases,
3767 sourcing the scripts directly would fail anyway, but with
3768 harder-to-interpret messages.
3774 Fix incorrect coding in <filename>contrib/dict_int</> and
3775 <filename>contrib/dict_xsyn</> (Tom Lane)
3779 Some functions incorrectly assumed that memory returned by
3780 <function>palloc()</> is guaranteed zeroed.
3786 Remove <filename>contrib/sepgsql</> tests from the regular regression
3787 test mechanism (Tom Lane)
3791 Since these tests require root privileges for setup, they're impractical
3792 to run automatically. Switch over to a manual approach instead, and
3793 provide a testing script to help with that.
3799 Fix assorted errors in <filename>contrib/unaccent</>'s configuration
3800 file parsing (Tom Lane)
3806 Honor query cancel interrupts promptly in <function>pgstatindex()</>
3813 Fix incorrect quoting of log file name in Mac OS X start script
3820 Revert unintentional enabling of <literal>WAL_DEBUG</> (Robert Haas)
3824 Fortunately, as debugging tools go, this one is pretty cheap;
3825 but it's not intended to be enabled by default, so revert.
3831 Ensure VPATH builds properly install all server header files
3838 Shorten file names reported in verbose error messages (Peter Eisentraut)
3842 Regular builds have always reported just the name of the C file
3843 containing the error message call, but VPATH builds formerly
3844 reported an absolute path name.
3850 Fix interpretation of Windows timezone names for Central America
3855 Map <quote>Central America Standard Time</> to <literal>CST6</>, not
3856 <literal>CST6CDT</>, because DST is generally not observed anywhere in
3863 Update time zone data files to <application>tzdata</> release 2011n
3864 for DST law changes in Brazil, Cuba, Fiji, Palestine, Russia, and Samoa;
3865 also historical corrections for Alaska and British East Africa.
3874 <sect1 id="release-9-1-1">
3875 <title>Release 9.1.1</title>
3878 <title>Release Date</title>
3879 <simpara>2011-09-26</simpara>
3883 This release contains a small number of fixes from 9.1.0.
3884 For information about new features in the 9.1 major release, see
3885 <xref linkend="release-9-1">.
3889 <title>Migration to Version 9.1.1</title>
3892 A dump/restore is not required for those running 9.1.X.
3898 <title>Changes</title>
3904 Make <function>pg_options_to_table</> return NULL for an option with no
3909 Previously such cases would result in a server crash.
3915 Fix memory leak at end of a GiST index scan (Tom Lane)
3919 Commands that perform many separate GiST index scans, such as
3920 verification of a new GiST-based exclusion constraint on a table
3921 already containing many rows, could transiently require large amounts of
3922 memory due to this leak.
3928 Fix explicit reference to <literal>pg_temp</> schema in <command>CREATE
3929 TEMPORARY TABLE</> (Robert Haas)
3933 This used to be allowed, but failed in 9.1.0.
3942 <sect1 id="release-9-1">
3943 <title>Release 9.1</title>
3946 <title>Release Date</title>
3947 <simpara>2011-09-12</simpara>
3951 <title>Overview</title>
3954 This release shows <productname>PostgreSQL</> moving beyond the
3955 traditional relational-database feature set with new, ground-breaking
3956 functionality that is unique to <productname>PostgreSQL</>.
3957 The streaming replication feature introduced in release 9.0 is
3958 significantly enhanced by adding a synchronous-replication option,
3959 streaming backups, and monitoring improvements.
3960 Major enhancements include:
3965 <!-- This list duplicates items below, but without authors or details-->
3969 Allow <link linkend="synchronous-replication">synchronous
3976 Add support for <link linkend="SQL-CREATEFOREIGNTABLE">foreign
3983 Add per-column <link
3984 linkend="collation">collation</link> support
3990 Add <link linkend="extend-extensions">extensions</link> which
3991 simplify packaging of additions to <productname>PostgreSQL</>
3998 linkend="xact-serializable">serializable isolation level</link>
4004 Support unlogged tables using the <literal>UNLOGGED</>
4005 option in <link linkend="SQL-CREATETABLE"><command>CREATE
4012 Allow data-modification commands
4013 (<command>INSERT</>/<command>UPDATE</>/<command>DELETE</>) in
4014 <link linkend="queries-with"><literal>WITH</></link> clauses
4020 Add nearest-neighbor (order-by-operator) searching to <link
4021 linkend="GiST"><acronym>GiST</> indexes</link>
4027 Add a <link linkend="SQL-SECURITY-LABEL"><command>SECURITY
4028 LABEL</></link> command and support for
4029 <link linkend="sepgsql"><acronym>SELinux</> permissions control</link>
4035 Update the <link linkend="plpython">PL/Python</link> server-side
4043 The above items are explained in more detail in the sections below.
4050 <title>Migration to Version 9.1</title>
4053 A dump/restore using <application>pg_dump</application>,
4054 or use of <application>pg_upgrade</application>, is required
4055 for those wishing to migrate data from any previous
4060 Version 9.1 contains a number of changes that may affect compatibility
4061 with previous releases. Observe the following incompatibilities:
4065 <title>Strings</title>
4071 Change the default value of <link
4072 linkend="guc-standard-conforming-strings"><varname>standard_conforming_strings</></link>
4077 By default, backslashes are now ordinary characters in string literals,
4078 not escape characters. This change removes a long-standing
4079 incompatibility with the SQL standard. <link
4080 linkend="guc-escape-string-warning"><varname>escape_string_warning</></link>
4081 has produced warnings about this usage for years. <literal>E''</>
4082 strings are the proper way to embed backslash escapes in strings and are
4083 unaffected by this change.
4088 This change can break applications that are not expecting it and
4089 do their own string escaping according to the old rules. The
4090 consequences could be as severe as introducing SQL-injection security
4091 holes. Be sure to test applications that are exposed to untrusted
4092 input, to ensure that they correctly handle single quotes and
4093 backslashes in text strings.
4103 <title>Casting</title>
4109 Disallow function-style and attribute-style data type casts for
4110 composite types (Tom Lane)
4114 For example, disallow
4115 <literal><replaceable>composite_value</>.text</literal> and
4116 <literal>text(<replaceable>composite_value</>)</literal>.
4117 Unintentional uses of this syntax have frequently resulted in bug
4118 reports; although it was not a bug, it seems better to go back to
4119 rejecting such expressions.
4120 The <literal>CAST</> and <literal>::</> syntaxes are still available
4121 for use when a cast of an entire composite value is actually intended.
4127 Tighten casting checks for domains based on arrays (Tom Lane)
4131 When a domain is based on an array type, it is allowed to <quote>look
4132 through</> the domain type to access the array elements, including
4133 subscripting the domain value to fetch or assign an element.
4134 Assignment to an element of such a domain value, for instance via
4135 <literal>UPDATE ... SET domaincol[5] = ...</>, will now result in
4136 rechecking the domain type's constraints, whereas before the checks
4146 <title>Arrays</title>
4153 linkend="array-functions-table"><function>string_to_array()</></link>
4154 to return an empty array for a zero-length string (Pavel
4159 Previously this returned a null value.
4166 linkend="array-functions-table"><function>string_to_array()</></link>
4167 so a <literal>NULL</> separator splits the string into characters
4172 Previously this returned a null value.
4181 <title>Object Modification</title>
4187 Fix improper checks for before/after triggers (Tom Lane)
4191 Triggers can now be fired in three cases: <literal>BEFORE</>,
4192 <literal>AFTER</>, or <literal>INSTEAD OF</> some action.
4193 Trigger function authors should verify that their logic behaves
4194 sanely in all three cases.
4200 Require superuser or <literal>CREATEROLE</> permissions in order to
4201 set comments on roles (Tom Lane)
4210 <title>Server Settings</title>
4217 linkend="functions-recovery-info-table"><function>pg_last_xlog_receive_location()</></link>
4218 so it never moves backwards (Fujii Masao)
4222 Previously, the value of <function>pg_last_xlog_receive_location()</>
4223 could move backward when streaming replication is restarted.
4229 Have logging of replication connections honor <link
4230 linkend="guc-log-connections"><varname>log_connections</></link>
4235 Previously, replication connections were always logged.
4244 <title><link linkend="plpgsql">PL/pgSQL</link> Server-Side Language</title>
4250 Change PL/pgSQL's <literal>RAISE</> command without parameters
4251 to be catchable by the attached exception block (Piyush Newe)
4255 Previously <literal>RAISE</> in a code block was always scoped to
4256 an attached exception block, so it was uncatchable at the same
4263 Adjust PL/pgSQL's error line numbering code to be consistent
4264 with other PLs (Pavel Stehule)
4268 Previously, PL/pgSQL would ignore (not count) an empty line at the
4269 start of the function body. Since this was inconsistent with all
4270 other languages, the special case was removed.
4276 Make PL/pgSQL complain about conflicting IN and OUT parameter names
4281 Formerly, the collision was not detected, and the name would just
4282 silently refer to only the OUT parameter.
4288 Type modifiers of PL/pgSQL variables are now visible to the SQL parser
4293 A type modifier (such as a varchar length limit) attached to a PL/pgSQL
4294 variable was formerly enforced during assignments, but was ignored for
4295 all other purposes. Such variables will now behave more like table
4296 columns declared with the same modifier. This is not expected to make
4297 any visible difference in most cases, but it could result in subtle
4298 changes for some SQL commands issued by PL/pgSQL functions.
4307 <title>Contrib</title>
4313 All contrib modules are now installed with <link
4314 linkend="SQL-CREATEEXTENSION"><command>CREATE EXTENSION</></link>
4315 rather than by manually invoking their SQL scripts
4316 (Dimitri Fontaine, Tom Lane)
4320 To update an existing database containing the 9.0 version of a contrib
4321 module, use <literal>CREATE EXTENSION ... FROM unpackaged</literal>
4322 to wrap the existing contrib module's objects into an extension. When
4323 updating from a pre-9.0 version, drop the contrib module's objects
4324 using its old uninstall script, then use <literal>CREATE EXTENSION</>.
4333 <title>Other Incompatibilities</title>
4340 linkend="monitoring-stats-funcs-table"><function>pg_stat_reset()</></link>
4341 reset all database-level statistics (Tomas Vondra)
4345 Some <structname>pg_stat_database</> counters were not being reset.
4352 linkend="infoschema-triggers"><structname>information_schema.triggers</></link>
4353 column names to match the new SQL-standard names (Dean Rasheed)
4359 Treat <application>ECPG</> cursor names as case-insensitive
4360 (Zoltan Boszormenyi)
4370 <title>Changes</title>
4373 Below you will find a detailed account of the changes between
4374 <productname>PostgreSQL</productname> 9.1 and the previous major
4379 <title>Server</title>
4382 <title>Performance</title>
4388 Support unlogged tables using the <literal>UNLOGGED</>
4389 option in <link linkend="SQL-CREATETABLE"><command>CREATE
4390 TABLE</></link> (Robert Haas)
4394 Such tables provide better update performance than regular tables,
4395 but are not crash-safe: their contents are automatically cleared in
4396 case of a server crash. Their contents do not propagate to
4397 replication slaves, either.
4403 Allow <literal>FULL OUTER JOIN</literal> to be implemented as a
4404 hash join, and allow either side of a <literal>LEFT OUTER JOIN</>
4405 or <literal>RIGHT OUTER JOIN</> to be hashed (Tom Lane)
4409 Previously <literal>FULL OUTER JOIN</literal> could only be
4410 implemented as a merge join, and <literal>LEFT OUTER JOIN</literal>
4411 and <literal>RIGHT OUTER JOIN</literal> could hash only the nullable
4412 side of the join. These changes provide additional query optimization
4419 Merge duplicate fsync requests (Robert Haas, Greg Smith)
4423 This greatly improves performance under heavy write loads.
4429 Improve performance of <link
4430 linkend="guc-commit-siblings"><varname>commit_siblings</></link>
4435 This allows the use of <varname>commit_siblings</varname> with
4442 Reduce the memory requirement for large ispell dictionaries
4443 (Pavel Stehule, Tom Lane)
4449 Avoid leaving data files open after <quote>blind writes</>
4454 This fixes scenarios in which backends might hold files open long
4455 after they were deleted, preventing the kernel from reclaiming
4465 <title>Optimizer</title>
4471 Allow inheritance table scans to return meaningfully-sorted
4472 results (Greg Stark, Hans-Jurgen Schonig, Robert Haas, Tom Lane)
4476 This allows better optimization of queries that use <literal>ORDER
4477 BY</>, <literal>LIMIT</>, or <literal>MIN</>/<literal>MAX</> with
4484 Improve GIN index scan cost estimation (Teodor Sigaev)
4490 Improve cost estimation for aggregates and window functions (Tom Lane)
4499 <title>Authentication</title>
4505 Support host names and host suffixes
4506 (e.g. <literal>.example.com</>) in <link
4507 linkend="auth-pg-hba-conf"><filename>pg_hba.conf</></link>
4512 Previously only host <acronym>IP</> addresses and <acronym>CIDR</>
4513 values were supported.
4519 Support the key word <literal>all</> in the host column of <link
4520 linkend="auth-pg-hba-conf"><filename>pg_hba.conf</></link>
4525 Previously people used <literal>0.0.0.0/0</> or <literal>::/0</>
4532 Reject <literal>local</> lines in <link
4533 linkend="auth-pg-hba-conf"><filename>pg_hba.conf</></link>
4534 on platforms that don't support Unix-socket connections
4539 Formerly, such lines were silently ignored, which could be surprising.
4540 This makes the behavior more like other unsupported cases.
4546 Allow <link linkend="gssapi-auth"><acronym>GSSAPI</></link>
4547 to be used to authenticate to servers via <link
4548 linkend="sspi-auth"><acronym>SSPI</></link> (Christian Ullrich)
4552 Specifically this allows Unix-based <acronym>GSSAPI</> clients
4553 to do <acronym>SSPI</> authentication with Windows servers.
4559 <link linkend="auth-ident"><literal>ident</literal></link>
4560 authentication over local sockets is now known as
4561 <link linkend="auth-peer"><literal>peer</literal></link>
4566 The old term is still accepted for backward compatibility, but since
4567 the two methods are fundamentally different, it seemed better to adopt
4568 different names for them.
4574 Rewrite <link linkend="auth-peer"><acronym>peer</></link>
4575 authentication to avoid use of credential control messages (Tom Lane)
4579 This change makes the peer authentication code simpler and
4580 better-performing. However, it requires the platform to provide the
4581 <function>getpeereid</> function or an equivalent socket operation.
4582 So far as is known, the only platform for which peer authentication
4583 worked before and now will not is pre-5.0 NetBSD.
4592 <title>Monitoring</title>
4598 Add details to the logging of restartpoints and checkpoints,
4599 which is controlled by <link
4600 linkend="guc-log-checkpoints"><varname>log_checkpoints</></link>
4601 (Fujii Masao, Greg Smith)
4605 New details include <acronym>WAL</> file and sync activity.
4612 linkend="guc-log-file-mode"><varname>log_file_mode</></link>
4613 which controls the permissions on log files created by the
4614 logging collector (Martin Pihlak)
4620 Reduce the default maximum line length for <application>syslog</>
4621 logging to 900 bytes plus prefixes (Noah Misch)
4625 This avoids truncation of long log lines on syslog implementations
4626 that have a 1KB length limit, rather than the more common 2KB.
4635 <title>Statistical Views</title>
4641 Add <structfield>client_hostname</structfield> column to <link
4642 linkend="monitoring-stats-views-table"><structname>pg_stat_activity</></link>
4647 Previously only the client address was reported.
4654 linkend="monitoring-stats-views-table"><structname>pg_stat_xact_*</></link>
4655 statistics functions and views (Joel Jacobson)
4659 These are like the database-wide statistics counter views, but
4660 reflect counts for only the current transaction.
4666 Add time of last reset in database-level and background writer
4667 statistics views (Tomas Vondra)
4673 Add columns showing the number of vacuum and analyze operations
4675 linkend="monitoring-stats-views-table"><structname>pg_stat_*_tables</></link>
4676 views (Magnus Hagander)
4682 Add <structfield>buffers_backend_fsync</> column to <link
4683 linkend="monitoring-stats-views-table"><structname>pg_stat_bgwriter</></link>
4688 This new column counts the number of times a backend fsyncs a
4698 <title>Server Settings</title>
4704 Provide auto-tuning of <link
4705 linkend="guc-wal-buffers"><varname>wal_buffers</></link> (Greg
4710 By default, the value of <varname>wal_buffers</> is now chosen
4711 automatically based on the value of <varname>shared_buffers</>.
4717 Increase the maximum values for
4718 <link linkend="guc-deadlock-timeout"><varname>deadlock_timeout</varname></link>,
4719 <link linkend="guc-log-min-duration-statement"><varname>log_min_duration_statement</varname></link>, and
4720 <link linkend="guc-log-autovacuum-min-duration"><varname>log_autovacuum_min_duration</varname></link>
4725 The maximum value for each of these parameters was previously
4726 only about 35 minutes. Much larger values are now allowed.
4737 <title>Replication and Recovery</title>
4740 <title>Streaming Replication and Continuous Archiving</title>
4746 Allow <link linkend="synchronous-replication">synchronous
4747 replication</link> (Simon Riggs, Fujii Masao)
4751 This allows the primary server to wait for a standby to write a
4752 transaction's information to disk before acknowledging the commit.
4753 One standby at a time can take the role of the synchronous standby,
4754 as controlled by the
4755 <link linkend="guc-synchronous-standby-names"><varname>synchronous_standby_names</varname></link>
4756 setting. Synchronous replication can be enabled or disabled on a
4757 per-transaction basis using the
4758 <link linkend="guc-synchronous-commit"><varname>synchronous_commit</></link>
4765 Add protocol support for sending file system backups to standby servers
4766 using the streaming replication network connection (Magnus Hagander,
4771 This avoids the requirement of manually transferring a file
4772 system backup when setting up a standby server.
4779 <varname>replication_timeout</>
4780 setting (Fujii Masao, Heikki Linnakangas)
4784 Replication connections that are idle for more than the
4785 <varname>replication_timeout</> interval will be terminated
4786 automatically. Formerly, a failed connection was typically not
4787 detected until the TCP timeout elapsed, which is inconveniently
4788 long in many situations.
4794 Add command-line tool <link
4795 linkend="app-pgbasebackup"><application>pg_basebackup</></link>
4796 for creating a new standby server or database backup (Magnus
4803 Add a <link linkend="SQL-CREATEROLE">replication permission</link>
4804 for roles (Magnus Hagander)
4808 This is a read-only permission used for streaming replication.
4809 It allows a non-superuser role to be used for replication connections.
4810 Previously only superusers could initiate replication
4811 connections; superusers still have this permission by default.
4820 <title>Replication Monitoring</title>
4826 Add system view <link
4827 linkend="monitoring-stats-views-table"><structname>pg_stat_replication</></link>
4828 which displays activity of <acronym>WAL</> sender processes (Itagaki
4829 Takahiro, Simon Riggs)
4833 This reports the status of all connected standby servers.
4839 Add monitoring function <link
4840 linkend="functions-recovery-info-table"><function>pg_last_xact_replay_timestamp()</></link>
4845 This returns the time at which the primary generated the most
4846 recent commit or abort record applied on the standby.
4855 <title>Hot Standby</title>
4861 Add configuration parameter <link
4862 linkend="guc-hot-standby-feedback"><varname>hot_standby_feedback</></link>
4863 to enable standbys to postpone cleanup of old row versions on the
4864 primary (Simon Riggs)
4868 This helps avoid canceling long-running queries on the standby.
4875 linkend="monitoring-stats-views-table"><structname>pg_stat_database_conflicts</></link>
4876 system view to show queries that have been canceled and the
4877 reason (Magnus Hagander)
4881 Cancellations can occur because of dropped tablespaces, lock
4882 timeouts, old snapshots, pinned buffers, and deadlocks.
4888 Add a <structfield>conflicts</> count to <link
4889 linkend="monitoring-stats-views-table"><structname>pg_stat_database</></link>
4894 This is the number of conflicts that occurred in the database.
4900 Increase the maximum values for
4901 <link linkend="guc-max-standby-archive-delay"><varname>max_standby_archive_delay</varname></link> and
4902 <link linkend="guc-max-standby-streaming-delay"><varname>max_standby_streaming_delay</varname></link>
4906 The maximum value for each of these parameters was previously
4907 only about 35 minutes. Much larger values are now allowed.
4914 linkend="errcodes-table"><literal>ERRCODE_T_R_DATABASE_DROPPED</></link>
4915 error code to report recovery conflicts due to dropped databases
4920 This is useful for connection pooling software.
4929 <title>Recovery Control</title>
4935 Add functions to control streaming replication replay (Simon Riggs)
4939 The new functions are <link
4940 linkend="functions-recovery-control-table"><function>pg_xlog_replay_pause()</></link>,
4942 linkend="functions-recovery-control-table"><function>pg_xlog_replay_resume()</></link>,
4943 and the status function <link
4944 linkend="functions-recovery-control-table"><function>pg_is_xlog_replay_paused()</></link>.
4950 Add <filename>recovery.conf</> setting <link
4951 linkend="pause-at-recovery-target"><varname>pause_at_recovery_target</></link>
4952 to pause recovery at target (Simon Riggs)
4956 This allows a recovery server to be queried to check whether
4957 the recovery point is the one desired.
4963 Add the ability to create named restore points using <link
4964 linkend="functions-admin-backup-table"><function>pg_create_restore_point()</></link>
4969 These named restore points can be specified as recovery
4970 targets using the new <filename>recovery.conf</> setting
4971 <link linkend="recovery-target-name"><varname>recovery_target_name</></link>.
4977 Allow standby recovery to switch to a new timeline automatically
4978 (Heikki Linnakangas)
4982 Now standby servers scan the archive directory for new
4983 timelines periodically.
4990 linkend="guc-restart-after-crash"><varname>restart_after_crash</></link>
4991 setting which disables automatic server restart after a backend
4996 This allows external cluster management software to control
4997 whether the database server restarts or not.
5004 linkend="recovery-config"><filename>recovery.conf</></link>
5005 to use the same quoting behavior as <filename>postgresql.conf</>
5010 Previously all values had to be quoted.
5021 <title>Queries</title>
5028 linkend="xact-serializable">serializable isolation level</link>
5029 (Kevin Grittner, Dan Ports)
5033 Previously, asking for serializable isolation guaranteed only that a
5034 single MVCC snapshot would be used for the entire transaction, which
5035 allowed certain documented anomalies. The old snapshot isolation
5036 behavior is still available by requesting the <link
5037 linkend="xact-repeatable-read"><literal>REPEATABLE READ</></link>
5044 Allow data-modification commands
5045 (<command>INSERT</>/<command>UPDATE</>/<command>DELETE</>) in
5046 <link linkend="queries-with"><literal>WITH</></link> clauses
5047 (Marko Tiikkaja, Hitoshi Harada)
5051 These commands can use <literal>RETURNING</> to pass data up to the
5058 Allow <link linkend="queries-with"><literal>WITH</></link>
5059 clauses to be attached to <command>INSERT</>, <command>UPDATE</>,
5060 <command>DELETE</> statements (Marko Tiikkaja, Hitoshi Harada)
5066 Allow non-<link linkend="queries-group"><literal>GROUP
5067 BY</></link> columns in the query target list when the primary
5068 key is specified in the <literal>GROUP BY</> clause (Peter
5073 The SQL standard allows this behavior, and
5074 because of the primary key, the result is unambiguous.
5080 Allow use of the key word <literal>DISTINCT</> in <link
5081 linkend="queries-union"><literal>UNION</>/<literal>INTERSECT</>/<literal>EXCEPT</></link>
5086 <literal>DISTINCT</> is the default behavior so use of this
5087 key word is redundant, but the SQL standard allows it.
5093 Fix ordinary queries with rules to use the same snapshot behavior
5094 as <command>EXPLAIN ANALYZE</> (Marko Tiikkaja)
5098 Previously <command>EXPLAIN ANALYZE</> used slightly different
5099 snapshot timing for queries involving rules. The
5100 <command>EXPLAIN ANALYZE</> behavior was judged to be more logical.
5107 <title>Strings</title>
5113 Add per-column <link
5114 linkend="collation">collation</link> support
5115 (Peter Eisentraut, Tom Lane)
5119 Previously collation (the sort ordering of text strings) could only be
5120 chosen at database creation.
5121 Collation can now be set per column, domain, index, or
5122 expression, via the SQL-standard <literal>COLLATE</> clause.
5133 <title>Object Manipulation</title>
5139 Add <link linkend="extend-extensions">extensions</link> which
5140 simplify packaging of additions to <productname>PostgreSQL</>
5141 (Dimitri Fontaine, Tom Lane)
5145 Extensions are controlled by the new <link
5146 linkend="SQL-CREATEEXTENSION"><command>CREATE</></link>/<link
5147 linkend="SQL-ALTEREXTENSION"><command>ALTER</></link>/<link
5148 linkend="SQL-DROPEXTENSION"><command>DROP EXTENSION</></link>
5149 commands. This replaces ad-hoc methods of grouping objects that
5150 are added to a <productname>PostgreSQL</> installation.
5156 Add support for <link linkend="SQL-CREATEFOREIGNTABLE">foreign
5157 tables</link> (Shigeru Hanada, Robert Haas, Jan Urbanski,
5162 This allows data stored outside the database to be used like
5163 native <productname>PostgreSQL</>-stored data. Foreign tables
5164 are currently read-only, however.
5170 Allow new values to be added to an existing enum type via
5171 <link linkend="SQL-ALTERTYPE"><command>ALTER TYPE</></link> (Andrew
5178 Add <link linkend="SQL-ALTERTYPE"><command>ALTER TYPE ...
5179 ADD/DROP/ALTER/RENAME ATTRIBUTE</></link> (Peter Eisentraut)
5183 This allows modification of composite types.
5190 <title><command>ALTER</> Object</title>
5196 Add <literal>RESTRICT</>/<literal>CASCADE</> to <link
5197 linkend="SQL-ALTERTYPE"><command>ALTER TYPE</></link> operations
5198 on typed tables (Peter Eisentraut)
5203 <literal>ADD</>/<literal>DROP</>/<literal>ALTER</>/<literal>RENAME
5204 ATTRIBUTE</> cascading behavior.
5210 Support <literal>ALTER TABLE <replaceable>name</> {OF | NOT OF}
5211 <replaceable>type</></literal>
5216 This syntax allows a standalone table to be made into a typed table,
5217 or a typed table to be made standalone.
5223 Add support for more object types in <command>ALTER ... SET
5224 SCHEMA</> commands (Dimitri Fontaine)
5228 This command is now supported for conversions, operators, operator
5229 classes, operator families, text search configurations, text search
5230 dictionaries, text search parsers, and text search templates.
5239 <title><link linkend="SQL-CREATETABLE"><command>CREATE/ALTER TABLE</></link></title>
5245 Add <command>ALTER TABLE ...
5246 ADD UNIQUE/PRIMARY KEY USING INDEX</command>
5251 This allows a primary key or unique constraint to be defined using an
5252 existing unique index, including a concurrently created unique index.
5258 Allow <command>ALTER TABLE</>
5259 to add foreign keys without validation (Simon Riggs)
5263 The new option is called <literal>NOT VALID</>. The constraint's
5264 state can later be modified to <literal>VALIDATED</> and validation
5265 checks performed. Together these allow you to add a foreign key
5266 with minimal impact on read and write operations.
5272 Allow <link linkend="SQL-ALTERTABLE"><command>ALTER TABLE
5273 ... SET DATA TYPE</command></link> to avoid table rewrites in
5274 appropriate cases (Noah Misch, Robert Haas)
5278 For example, converting a <type>varchar</> column to
5279 <type>text</> no longer requires a rewrite of the table.
5280 However, increasing the length constraint on a
5281 <type>varchar</> column still requires a table rewrite.
5287 Add <link linkend="SQL-CREATETABLE"><command>CREATE TABLE IF
5288 NOT EXISTS</></link> syntax (Robert Haas)
5292 This allows table creation without causing an error if the
5293 table already exists.
5299 Fix possible <quote>tuple concurrently updated</quote> error
5300 when two backends attempt to add an inheritance
5301 child to the same table at the same time (Robert Haas)
5305 <link linkend="sql-altertable"><command>ALTER TABLE</command></link>
5306 now takes a stronger lock on the parent table, so that the sessions
5307 cannot try to update it simultaneously.
5316 <title>Object Permissions</title>
5322 Add a <link linkend="SQL-SECURITY-LABEL"><command>SECURITY
5323 LABEL</></link> command (KaiGai Kohei)
5327 This allows security labels to be assigned to objects.
5338 <title>Utility Operations</title>
5344 Add transaction-level <link linkend="advisory-locks">advisory
5345 locks</link> (Marko Tiikkaja)
5349 These are similar to the existing session-level advisory locks,
5350 but such locks are automatically released at transaction end.
5356 Make <link linkend="SQL-TRUNCATE"><command>TRUNCATE ... RESTART
5357 IDENTITY</></link> restart sequences transactionally (Steve
5362 Previously the counter could have been left out of sync if a
5363 backend crashed between the on-commit truncation activity and
5371 <title><link linkend="SQL-COPY"><command>COPY</></link></title>
5377 Add <literal>ENCODING</> option to <link
5378 linkend="SQL-COPY"><command>COPY TO/FROM</></link> (Hitoshi
5379 Harada, Itagaki Takahiro)
5383 This allows the encoding of the <command>COPY</> file to be
5384 specified separately from client encoding.
5390 Add bidirectional <link linkend="SQL-COPY"><command>COPY</></link>
5391 protocol support (Fujii Masao)
5395 This is currently only used by streaming replication.
5404 <title><link linkend="SQL-EXPLAIN"><command>EXPLAIN</></link></title>
5410 Make <command>EXPLAIN VERBOSE</> show the function call expression
5411 in a <literal>FunctionScan</literal> node (Tom Lane)
5420 <title><link linkend="SQL-VACUUM"><command>VACUUM</></link></title>
5426 Add additional details to the output of <link
5427 linkend="SQL-VACUUM"><command>VACUUM FULL VERBOSE</></link>
5428 and <link linkend="SQL-CLUSTER"><command>CLUSTER VERBOSE</></link>
5433 New information includes the live and dead tuple count and
5434 whether <command>CLUSTER</> is using an index to rebuild.
5440 Prevent <link linkend="autovacuum">autovacuum</link> from
5441 waiting if it cannot acquire a table lock (Robert Haas)
5445 It will try to vacuum that table later.
5454 <title><link linkend="SQL-CLUSTER"><command>CLUSTER</></link></title>
5460 Allow <command>CLUSTER</> to sort the table rather than scanning
5461 the index when it seems likely to be cheaper (Leonardo Francalanci)
5470 <title>Indexes</title>
5476 Add nearest-neighbor (order-by-operator) searching to <link
5477 linkend="GiST"><acronym>GiST</> indexes</link> (Teodor Sigaev, Tom Lane)
5481 This allows <acronym>GiST</> indexes to quickly return the
5482 <replaceable>N</> closest values in a query with <literal>LIMIT</>.
5484 <programlisting><![CDATA[
5485 SELECT * FROM places ORDER BY location <-> point '(101,456)' LIMIT 10;
5488 finds the ten places closest to a given target point.
5494 Allow <link linkend="GIN"><acronym>GIN</> indexes</link> to index null
5495 and empty values (Tom Lane)
5499 This allows full <acronym>GIN</> index scans, and fixes various
5500 corner cases in which GIN scans would fail.
5506 Allow <link linkend="GIN"><acronym>GIN</> indexes</link> to
5507 better recognize duplicate search entries (Tom Lane)
5511 This reduces the cost of index scans, especially in cases where
5512 it avoids unnecessary full index scans.
5518 Fix <link linkend="GiST"><acronym>GiST</> indexes</link> to be fully
5519 crash-safe (Heikki Linnakangas)
5523 Previously there were rare cases where a <command>REINDEX</>
5524 would be required (you would be informed).
5535 <title>Data Types</title>
5541 Allow <type>numeric</> to use a more compact, two-byte header
5542 in common cases (Robert Haas)
5546 Previously all <type>numeric</> values had four-byte headers;
5547 this change saves on disk storage.
5553 Add support for dividing <type>money</> by <type>money</>
5560 Allow binary I/O on type <type>void</type> (Radoslaw Smogura)
5566 Improve hypotenuse calculations for geometric operators (Paul Matthews)
5570 This avoids unnecessary overflows, and may also be more accurate.
5576 Support hashing array values (Tom Lane)
5580 This provides additional query optimization possibilities.
5586 Don't treat a composite type as sortable unless all its column types
5587 are sortable (Tom Lane)
5591 This avoids possible <quote>could not identify a comparison function</>
5592 failures at runtime, if it is possible to implement the query without
5593 sorting. Also, <command>ANALYZE</> won't try to use inappropriate
5594 statistics-gathering methods for columns of such composite types.
5601 <title>Casting</title>
5607 Add support for casting between <type>money</> and <type>numeric</>
5614 Add support for casting from <type>int4</> and <type>int8</>
5615 to <type>money</> (Joey Adams)
5621 Allow casting a table's row type to the table's supertype if
5622 it's a typed table (Peter Eisentraut)
5626 This is analogous to the existing facility that allows casting a row
5627 type to a supertable's row type.
5636 <title><link linkend="functions-xml"><acronym>XML</></link></title>
5642 Add <acronym>XML</> function <link
5643 linkend="xml-exists"><literal>XMLEXISTS</></link> and <link
5644 linkend="xml-exists"><function>xpath_exists()</></link>
5645 functions (Mike Fowler)
5649 These are used for XPath matching.
5655 Add <acronym>XML</> functions <link
5656 linkend="xml-is-well-formed"><function>xml_is_well_formed()</></link>,
5658 linkend="xml-is-well-formed"><function>xml_is_well_formed_document()</></link>,
5660 linkend="xml-is-well-formed"><function>xml_is_well_formed_content()</></link>
5665 These check whether the input is properly-formed <acronym>XML</>.
5666 They provide functionality that was previously available only in
5667 the deprecated <filename>contrib/xml2</filename> module.
5678 <title>Functions</title>
5684 Add SQL function <link
5685 linkend="format"><function>format(text, ...)</></link>, which
5686 behaves analogously to C's <function>printf()</> (Pavel Stehule,
5691 It currently supports formats for strings, SQL literals, and
5698 Add string functions <link
5699 linkend="functions-string-other"><function>concat()</></link>,
5701 linkend="functions-string-other"><function>concat_ws()</></link>,
5702 <link linkend="functions-string-other"><function>left()</></link>,
5703 <link linkend="functions-string-other"><function>right()</></link>,
5705 linkend="functions-string-other"><function>reverse()</></link>
5710 These improve compatibility with other database products.
5717 linkend="functions-admin-genfile"><function>pg_read_binary_file()</></link>
5718 to read binary files (Dimitri Fontaine, Itagaki Takahiro)
5724 Add a single-parameter version of function <link
5725 linkend="functions-admin-genfile"><function>pg_read_file()</></link>
5726 to read an entire file (Dimitri Fontaine, Itagaki Takahiro)
5732 Add three-parameter forms of <link
5733 linkend="array-functions-table"><function>array_to_string()</></link>
5735 linkend="array-functions-table"><function>string_to_array()</></link>
5736 for null value processing control (Pavel Stehule)
5743 <title>Object Information Functions</title>
5750 linkend="functions-info-catalog-table"><function>pg_describe_object()</></link>
5751 function (Alvaro Herrera)
5755 This function is used to obtain a human-readable string describing
5756 an object, based on the <link
5757 linkend="catalog-pg-class"><structname>pg_class</structname></link>
5758 OID, object OID, and sub-object ID. It can be used to help
5759 interpret the contents of <link
5760 linkend="catalog-pg-depend"><structname>pg_depend</structname></link>.
5766 Update comments for built-in operators and their underlying
5767 functions (Tom Lane)
5771 Functions that are meant to be used via an associated operator
5772 are now commented as such.
5779 linkend="guc-quote-all-identifiers"><varname>quote_all_identifiers</></link>
5780 to force the quoting of all identifiers in <command>EXPLAIN</>
5781 and in system catalog functions like <link
5782 linkend="functions-info-catalog-table"><function>pg_get_viewdef()</></link>
5787 This makes exporting schemas to tools and other databases with
5788 different quoting rules easier.
5794 Add columns to the <link
5795 linkend="infoschema-sequences"><structname>information_schema.sequences</></link>
5796 system view (Peter Eisentraut)
5800 Previously, though the view existed, the columns about the
5801 sequence parameters were unimplemented.
5807 Allow <literal>public</> as a pseudo-role name in <link
5808 linkend="functions-info-access-table"><function>has_table_privilege()</></link>
5809 and related functions (Alvaro Herrera)
5813 This allows checking for public permissions.
5822 <title>Function and Trigger Creation</title>
5828 Support <link linkend="SQL-CREATETRIGGER"><literal>INSTEAD
5829 OF</></link> triggers on views (Dean Rasheed)
5833 This feature can be used to implement fully updatable views.
5844 <title>Server-Side Languages</title>
5847 <title><link linkend="plpgsql">PL/pgSQL</link> Server-Side Language</title>
5853 Add <link linkend="plpgsql-foreach-array"><command>FOREACH IN
5854 ARRAY</></link> to PL/pgSQL
5859 This is more efficient and readable than previous methods of
5860 iterating through the elements of an array value.
5866 Allow <command>RAISE</command> without parameters to be caught in
5867 the same places that could catch a <command>RAISE ERROR</command>
5868 from the same location (Piyush Newe)
5872 The previous coding threw the error
5873 from the block containing the active exception handler.
5874 The new behavior is more consistent with other DBMS products.
5883 <title><link linkend="plperl">PL/Perl</link> Server-Side Language</title>
5889 Allow generic record arguments to PL/Perl functions (Andrew
5894 PL/Perl functions can now be declared to accept type <type>record</>.
5895 The behavior is the same as for any named composite type.
5901 Convert PL/Perl array arguments to Perl arrays (Alexey Klyukin,
5906 String representations are still available.
5912 Convert PL/Perl composite-type arguments to Perl hashes
5913 (Alexey Klyukin, Alex Hunsaker)
5917 String representations are still available.
5926 <title><link linkend="plpython">PL/Python</link> Server-Side Language</title>
5932 Add table function support for PL/Python (Jan Urbanski)
5936 PL/Python can now return multiple <literal>OUT</> parameters
5943 Add a validator to PL/Python (Jan Urbanski)
5947 This allows PL/Python functions to be syntax-checked at function
5954 Allow exceptions for SQL queries in PL/Python (Jan Urbanski)
5958 This allows access to SQL-generated exception error codes from
5959 PL/Python exception blocks.
5965 Add explicit subtransactions to PL/Python (Jan Urbanski)
5971 Add PL/Python functions for quoting strings (Jan Urbanski)
5975 These functions are <link
5976 linkend="plpython-util"><literal>plpy.quote_ident</></link>,
5977 <link linkend="plpython-util"><literal>plpy.quote_literal</></link>,
5979 linkend="plpython-util"><literal>plpy.quote_nullable</></link>.
5985 Add traceback information to PL/Python errors (Jan Urbanski)
5991 Report PL/Python errors from iterators with <literal>PLy_elog</> (Jan
5998 Fix exception handling with Python 3 (Jan Urbanski)
6002 Exception classes were previously not available in
6003 <literal>plpy</> under Python 3.
6014 <title>Client Applications</title>
6021 linkend="APP-CREATELANG"><application>createlang</></link>
6022 and <link linkend="APP-DROPLANG"><application>droplang</></link>
6023 as deprecated now that they just invoke extension commands (Tom
6031 <title><link linkend="APP-PSQL"><application>psql</></link></title>
6037 Add <application>psql</> command <literal>\conninfo</>
6038 to show current connection information (David Christensen)
6044 Add <application>psql</> command <literal>\sf</> to
6045 show a function's definition (Pavel Stehule)
6051 Add <application>psql</> command <literal>\dL</> to list
6052 languages (Fernando Ike)
6058 Add the <option>S</> (<quote>system</>) option to <application>psql</>'s
6059 <literal>\dn</> (list schemas) command (Tom Lane)
6063 <literal>\dn</> without <literal>S</> now suppresses system
6070 Allow <application>psql</>'s <literal>\e</> and <literal>\ef</>
6071 commands to accept a line number to be used to position the
6072 cursor in the editor (Pavel Stehule)
6076 This is passed to the editor according to the
6077 <envar>PSQL_EDITOR_LINENUMBER_ARG</> environment variable.
6083 Have <application>psql</> set the client encoding from the
6084 operating system locale by default (Heikki Linnakangas)
6088 This only happens if the <envar>PGCLIENTENCODING</> environment
6089 variable is not set.
6095 Make <literal>\d</literal> distinguish between unique
6096 indexes and unique constraints (Josh Kupershmidt)
6102 Make <literal>\dt+</literal> report <function>pg_table_size</>
6103 instead of <function>pg_relation_size</> when talking to 9.0 or
6104 later servers (Bernd Helmle)
6108 This is a more useful measure of table size, but note that it is
6109 not identical to what was previously reported in the same display.
6115 Additional tab completion support (Itagaki Takahiro, Pavel Stehule,
6116 Andrey Popp, Christoph Berg, David Fetter, Josh Kupershmidt)
6125 <title><link linkend="APP-PGDUMP"><application>pg_dump</></link></title>
6131 Add <link linkend="APP-PGDUMP"><application>pg_dump</></link>
6133 linkend="APP-PG-DUMPALL"><application>pg_dumpall</></link>
6134 option <option>--quote-all-identifiers</> to force quoting
6135 of all identifiers (Robert Haas)
6141 Add <literal>directory</> format to <application>pg_dump</>
6142 (Joachim Wieland, Heikki Linnakangas)
6146 This is internally similar to the <literal>tar</>
6147 <application>pg_dump</> format.
6156 <title><link linkend="APP-PG-CTL"><application>pg_ctl</></link></title>
6162 Fix <application>pg_ctl</>
6163 so it no longer incorrectly reports that the server is not
6164 running (Bruce Momjian)
6168 Previously this could happen if the server was running but
6169 <application>pg_ctl</> could not authenticate.
6175 Improve <application>pg_ctl</> start's <quote>wait</quote>
6176 (<option>-w</>) option (Bruce Momjian, Tom Lane)
6180 The wait mode is now significantly more robust. It will not get
6181 confused by non-default postmaster port numbers, non-default
6182 Unix-domain socket locations, permission problems, or stale
6183 postmaster lock files.
6189 Add <literal>promote</> option to <application>pg_ctl</> to
6190 switch a standby server to primary (Fujii Masao)
6201 <title><application>Development Tools</></title>
6204 <title><link linkend="libpq"><application>libpq</></link></title>
6210 Add a libpq connection option <link
6211 linkend="libpq-connect-client-encoding"><literal>client_encoding</></link>
6212 which behaves like the <envar>PGCLIENTENCODING</> environment
6213 variable (Heikki Linnakangas)
6217 The value <literal>auto</> sets the client encoding based on
6218 the operating system locale.
6225 linkend="libpq-pqlibversion"><function>PQlibVersion()</></link>
6226 function which returns the libpq library version (Magnus
6231 libpq already had <function>PQserverVersion()</> which returns
6238 Allow libpq-using clients to
6239 check the user name of the server process
6240 when connecting via Unix-domain sockets, with the new <link
6241 linkend="libpq-connect-requirepeer"><literal>requirepeer</></link>
6247 <productname>PostgreSQL</> already allowed servers to check
6248 the client user name when connecting via Unix-domain sockets.
6254 Add <link linkend="libpq-pqping"><function>PQping()</></link>
6256 linkend="libpq-pqpingparams"><function>PQpingParams()</></link>
6257 to libpq (Bruce Momjian, Tom Lane)
6261 These functions allow detection of the server's status without
6262 trying to open a new session.
6271 <title><link linkend="ecpg"><application>ECPG</></link></title>
6277 Allow ECPG to accept dynamic cursor names even in
6278 <literal>WHERE CURRENT OF</literal> clauses
6279 (Zoltan Boszormenyi)
6285 Make <application>ecpglib</> write <type>double</> values with a
6286 precision of 15 digits, not 14 as formerly (Akira Kurosawa)
6296 <title>Build Options</title>
6302 Use <literal>+Olibmerrno</> compile flag with HP-UX C compilers
6303 that accept it (Ibrar Ahmed)
6307 This avoids possible misbehavior of math library calls on recent
6315 <title>Makefiles</title>
6321 Improved parallel make support (Peter Eisentraut)
6325 This allows for faster compiles. Also, <literal>make -k</>
6326 now works more consistently.
6332 Require <acronym>GNU</> <link
6333 linkend="install-requirements"><application>make</></link>
6334 3.80 or newer (Peter Eisentraut)
6338 This is necessary because of the parallel-make improvements.
6344 Add <literal>make maintainer-check</> target
6349 This target performs various source code checks that are not
6350 appropriate for either the build or the regression tests. Currently:
6351 duplicate_oids, SGML syntax and tabs check, NLS syntax check.
6357 Support <literal>make check</> in <filename>contrib</>
6362 Formerly only <literal>make installcheck</> worked, but now
6363 there is support for testing in a temporary installation.
6364 The top-level <literal>make check-world</> target now includes
6365 testing <filename>contrib</> this way.
6374 <title>Windows</title>
6380 On Windows, allow <link
6381 linkend="app-pg-ctl"><application>pg_ctl</></link> to register
6382 the service as auto-start or start-on-demand (Quan Zongliang)
6388 Add support for collecting <link linkend="windows-crash-dumps">crash
6389 dumps</link> on Windows (Craig Ringer, Magnus Hagander)
6393 <productname>minidumps</> can now be generated by non-debug
6394 Windows binaries and analyzed by standard debugging tools.
6400 Enable building with the MinGW64 compiler (Andrew Dunstan)
6404 This allows building 64-bit Windows binaries even on non-Windows
6405 platforms via cross-compiling.
6416 <title>Source Code</title>
6422 Revise the API for GUC variable assign hooks (Tom Lane)
6426 The previous functions of assign hooks are now split between check
6427 hooks and assign hooks, where the former can fail but the latter
6428 shouldn't. This change will impact add-on modules that define custom
6435 Add latches to the source code to support waiting for events (Heikki
6442 Centralize data modification permissions-checking logic
6449 Add missing <function>get_<replaceable>object</>_oid()</function> functions, for consistency
6456 Improve ability to use C++ compilers for <link
6457 linkend="xfunc-c">compiling add-on modules</link> by removing
6458 conflicting key words (Tom Lane)
6464 Add support for DragonFly <acronym>BSD</> (Rumko)
6470 Expose <function>quote_literal_cstr()</> for backend use
6477 Run <link linkend="build">regression tests</link> in the
6478 default encoding (Peter Eisentraut)
6482 Regression tests were previously always run with
6483 <literal>SQL_ASCII</> encoding.
6489 Add <application>src/tools/git_changelog</> to replace
6490 <application>cvs2cl</> and <application>pgcvslog</> (Robert
6497 Add <application>git-external-diff</> script to
6498 <filename>src/tools</> (Bruce Momjian)
6502 This is used to generate context diffs from git.
6508 Improve support for building with
6509 <application>Clang</application> (Peter Eisentraut)
6516 <title>Server Hooks</title>
6522 Add source code hooks to check permissions (Robert Haas,
6529 Add post-object-creation function hooks for use by security
6530 frameworks (KaiGai Kohei)
6536 Add a client authentication hook (KaiGai Kohei)
6547 <title>Contrib</title>
6553 Modify <filename>contrib</> modules and procedural
6554 languages to install via the new <link
6555 linkend="extend-extensions">extension</link> mechanism (Tom Lane,
6562 Add <link linkend="file-fdw"><filename>contrib/file_fdw</></link>
6563 foreign-data wrapper (Shigeru Hanada)
6567 Foreign tables using this foreign data wrapper can read flat files
6568 in a manner very similar to <command>COPY</>.
6574 Add nearest-neighbor search support to <link
6575 linkend="pgtrgm"><filename>contrib/pg_trgm</></link> and <link
6576 linkend="btree-gist"><filename>contrib/btree_gist</></link>
6584 linkend="btree-gist"><filename>contrib/btree_gist</></link>
6585 support for searching on not-equals (Jeff Davis)
6592 linkend="fuzzystrmatch"><filename>contrib/fuzzystrmatch</></link>'s
6593 <function>levenshtein()</> function to handle multibyte characters
6594 (Alexander Korotkov)
6600 Add <function>ssl_cipher()</> and <function>ssl_version()</>
6602 linkend="sslinfo"><filename>contrib/sslinfo</></link> (Robert
6609 Fix <link linkend="intarray"><filename>contrib/intarray</></link>
6610 and <link linkend="hstore"><filename>contrib/hstore</></link>
6611 to give consistent results with indexed empty arrays (Tom Lane)
6615 Previously an empty-array query that used an index might return
6616 different results from one that used a sequential scan.
6622 Allow <link linkend="intarray"><filename>contrib/intarray</></link>
6623 to work properly on multidimensional arrays (Tom Lane)
6630 <link linkend="intarray"><filename>contrib/intarray</></link>,
6631 avoid errors complaining about the presence of nulls in cases where no
6632 nulls are actually present (Tom Lane)
6639 <link linkend="intarray"><filename>contrib/intarray</></link>,
6640 fix behavior of containment operators with respect to empty arrays
6645 Empty arrays are now correctly considered to be contained in any other
6652 Remove <link linkend="xml2"><filename>contrib/xml2</></link>'s
6653 arbitrary limit on the number of
6654 <replaceable>parameter</>=<replaceable>value</> pairs that can be
6655 handled by <function>xslt_process()</> (Pavel Stehule)
6659 The previous limit was 10.
6665 In <link linkend="pageinspect"><filename>contrib/pageinspect</></link>,
6666 fix heap_page_item to return infomasks as 32-bit values (Alvaro Herrera)
6670 This avoids returning negative values, which was confusing. The
6671 underlying value is a 16-bit unsigned integer.
6678 <title>Security</title>
6684 Add <link linkend="sepgsql"><filename>contrib/sepgsql</></link>
6685 to interface permission checks with <acronym>SELinux</> (KaiGai Kohei)
6689 This uses the new <link
6690 linkend="SQL-SECURITY-LABEL"><command>SECURITY LABEL</></link>
6697 Add contrib module <link
6698 linkend="auth-delay"><filename>auth_delay</></link> (KaiGai
6703 This causes the server to pause before returning authentication
6704 failure; it is designed to make brute force password attacks
6711 Add <link linkend="dummy-seclabel"><filename>dummy_seclabel</></link>
6712 contrib module (KaiGai Kohei)
6716 This is used for permission regression testing.
6725 <title>Performance</title>
6731 Add support for <literal>LIKE</> and <literal>ILIKE</> index
6733 linkend="pgtrgm"><filename>contrib/pg_trgm</></link> (Alexander
6740 Add <function>levenshtein_less_equal()</> function to <link
6741 linkend="fuzzystrmatch"><filename>contrib/fuzzystrmatch</></link>,
6742 which is optimized for small distances (Alexander Korotkov)
6748 Improve performance of index lookups on <link
6749 linkend="seg"><filename>contrib/seg</></link> columns (Alexander
6756 Improve performance of <link
6757 linkend="pgupgrade"><application>pg_upgrade</></link> for
6758 databases with many relations (Bruce Momjian)
6765 linkend="pgbench"><filename>contrib/pgbench</></link> to
6766 report per-statement latencies (Florian Pflug)
6775 <title>Fsync Testing</title>
6781 Move <filename>src/tools/test_fsync</> to <link
6782 linkend="pgtestfsync"><filename>contrib/pg_test_fsync</></link>
6783 (Bruce Momjian, Tom Lane)
6789 Add <literal>O_DIRECT</> support to <link
6790 linkend="pgtestfsync"><filename>contrib/pg_test_fsync</></link>
6795 This matches the use of <literal>O_DIRECT</> by <link
6796 linkend="guc-wal-sync-method"><varname>wal_sync_method</></link>.
6802 Add new tests to <link
6803 linkend="pgtestfsync"><filename>contrib/pg_test_fsync</></link>
6815 <title>Documentation</title>
6821 Extensive <link linkend="ecpg"><application>ECPG</></link>
6822 documentation improvements (Satoshi Nagayasu)
6828 Extensive proofreading and documentation improvements
6829 (Thom Brown, Josh Kupershmidt, Susanne Ebrecht)
6835 Add documentation for <link
6836 linkend="guc-exit-on-error"><varname>exit_on_error</></link>
6841 This parameter causes sessions to exit on any error.
6847 Add documentation for <link
6848 linkend="functions-info-catalog-table"><function>pg_options_to_table()</></link>
6853 This function shows table storage options in a readable form.
6859 Document that it is possible to access all composite type
6861 linkend="field-selection"><literal>(compositeval).*</></link>
6862 syntax (Peter Eisentraut)
6869 linkend="functions-string-other"><function>translate()</></link>
6870 removes characters in <literal>from</> that don't have a
6871 corresponding <literal>to</> character (Josh Kupershmidt)
6877 Merge documentation for <command>CREATE CONSTRAINT TRIGGER</> and <link
6878 linkend="SQL-CREATETRIGGER"><command>CREATE TRIGGER</></link>
6885 Centralize <link linkend="ddl-priv">permission</link> and <link
6886 linkend="upgrading">upgrade</link> documentation (Bruce Momjian)
6892 Add <link linkend="sysvipc-parameters">kernel tuning
6893 documentation</link> for Solaris 10 (Josh Berkus)
6897 Previously only Solaris 9 kernel tuning was documented.
6903 Handle non-ASCII characters consistently in <filename>HISTORY</> file
6908 While the <filename>HISTORY</> file is in English, we do have to deal
6909 with non-ASCII letters in contributor names. These are now
6910 transliterated so that they are reasonably legible without assumptions
6911 about character set.