Important Changes Between WHPG 6 and WHPG 7
There are a substantial number of changes between WarehousePG 6 and WarehousePG 7 that could potentially affect your existing 6 application when you move to 7. This topic provides information about these changes.
Naming Changes
The following table summarizes naming changes in WarehousePG 7:
Old Name | New Name |
---|---|
master | coordinator |
pg_log | log |
pg_xlog | pg_wal |
pg_clog | pg_xact |
xlog (includes SQL functions, tools and options) | wal |
pg_xlogdump | pg_waldump |
pg_resetxlog | pg_resetwal |
Deprecated Features
The following features have been deprecated in WarehousePG 7:
- The
gpreload
utility. Instead, useALTER TABLE...REPACK BY
.
Changes in Feature Behavior
The following feature behaviors have changed in WarehousePG 7:
The
checkpoint_segments
parameter in thepostgresql.conf
file has been removed. Use the server configuration parametersmin_wal_size
andmax_wal_size
, instead.Autovacuum is now enabled by default for all databases.
Pattern matching behavior of the
substring()
function has changed. In cases where the pattern can be matched in more than one way, the initial subpattern is now treated as matching the least possible amount of text rather than the greatest; for example, a pattern such as%#“aa*#”%
now selects the first group ofa
’s from the input, rather than the last group.Multi-dimensional arrays can now be passed into PL/Python functions, and returned as nested Python lists - Previously, you could return an array of composite values by writing, for exmaple,
[[col1, col2], [col1, col2]]
. Now, this is interpreted as a two-dimensional array. Composite types in arrays must now be written as Python tuples, not lists, to resolve the ambiguity; that is, you must write[(col1, col2), (col1, col2)]
, instead.When
x
is a table name or composite column, PostgreSQL has traditionally considered the syntactic formsf(x)
andx.f
to be equivalent, allowing tricks such as writing a function and then using it as though it were a computed-on-demand column. However, if both interpretations are feasible, the column interpretation was always chosen. Now, if there is ambiguity, the interpretation that matches the syntactic form is chosen.WarehousePG 7 now prevents the
to_number()
function from consuming characters when the template separator does not match. For example,SELECT to_number(‘1234’, ‘9,999’)
used to return134
. It will now return1234
, instead. L and TH now only consume characters that are not digits, positive/negative signs, decimal points, or commas.The
fix to_date()
,to_number()
, andto_timestamp()
functions previously skipped one byte for each byte of template character, resulting in strange behavior if either string contained multibyte characters. Adjust the handling of backslashes inside double-quotes in template strings for to_char(), to_number(), and to_timestamp(). Such a backslash now escapes the character after it, particularly a double-quote or another backslash.
Other Important Changes in WarehousePG 7
WarehousePG 7 also:
Removes some features and objects that were in Greeplum 6. See Features and Objects Removed in WarehousePG 7.
Changes some server configuration parameters. See Server Configuration Parameter Changes from WarehousePG 6 to WarehousePG 7.
Changes the partitioning system catalogs. See Changes in Partitioning and Migrating Partition Maintenance Scripts to the New WarehousePG 7 Partitioning Catalogs.
Makes changes to external tables. See Changes to External Tables.
Makes changes to resource groups. See Changes to Resource Groups.
Makes changes to system views and system tables. See System Catalog Changes between WarehousePG 6 and WarehousePG 7.