Re: 7.4 Press Release - Mailing list pgsql-advocacy

From Joe Conway
Subject Re: 7.4 Press Release
Date
Msg-id 3F14844E.3030803@joeconway.com
Whole thread Raw
In response to 7.4 Press Release  (Robert Treat <xzilla@users.sourceforge.net>)
Responses Re: 7.4 Press Release
List pgsql-advocacy
Robert Treat wrote:
> Significant advances in the new version include:
>

Maybe it's only significant to me ;-) but you might want to mention:

- significant enhancements to array data types, including support for
   btree indexes (details below in case you're interested)
- addition of polymorphic function arguments and return types

I think both of these are important for people doing scientific database
applications.

Also the INFORMATION SCHEMA probably deserves a mention.

> Questions / Comments:
>
> 2) What were the improvements for data warehousing? I don't remember
> anything specific to that cause.

Tom's hash aggregates performance improvement relates to data
warehousing applications. The "IN" clause improvements probably do also.
As do "expressional indexes".

>  - Pattern matching operations can use indexes regardless of locale
I know Peter talked about this one, but did it actually make it in to 7.4?

> 6) Where to put the complete changelog? On the developers site? We need
> a place going forward that makes sense for both major and minor
> releases...

There should be a link to the changelog on the download page and the
News item announcing the release, at a minimum.

Joe


I sent this to Bruce about a week ago:
Array and polymorphic functions: 7.4 Release Notes
---------------------------------------------------
1. Support for aggregate, SQL, PLpgSQL, and C language polymorphic
    functions:
    Polymorphic functions are those that accept as arguments,
    and optionally return, the data types ANYARRAY and ANYELEMENT,
    otherwise known as polymorphic types. These datatypes are "tied" to
    each other and resolved to an actual type at runtime. Each position
    (i.e. either argument or return type) defined as ANYELEMENT can have
    any data type at runtime, but they must all be the same runtime
    type. Each position defined as ANYARRAY can have any array data type
    at runtime, but similarly they must all be the same. If there are
    positions declared ANYARRAY and others declared ANYELEMENT, the
    runtime array type in the ANYARRAY positions must be an array of
    the runtime type at the ANYELEMENT positions.

2. Array expression syntax:
    Arrays may now be specified using the keyword ARRAY, followed by
    square brackets ("[" and "]") around a list of elements.
    Multidimensional arrays may be specified by nesting array
    expressions. In that case, the keyword ARRAY is optional for all
    but the outer dimension. Examples:
      ARRAY[1,2,3]
      ARRAY[['a','b'],['c','d']]
      ARRAY[ARRAY[ARRAY[2]]]

3. Modified array equality ("=") operator:
    array equality operator now applies the array element type's
    equality operator, element-by-element, instead of doing a
    byte-by-byte comparison

4. New array operators:
    "||" array-to-array concatenation (ARRAY[1,2,3] || ARRAY[4,5,6])
    "||" array-to-array concat (ARRAY[1,2,3]||ARRAY[[4,5,6],[7,8,9]])
    "||" element-to-array concatenation (3 || ARRAY[4,5,6])
    "||" array-to-element concatenation (ARRAY[4,5,6] || 7)
    "<" array less than array
    ">" array greater than array
    "<=" array less than or equal to array
    ">=" array greater than or equal to array
    "!=" array not equal to array

5. btree index and ordering support for arrays:
    Array columns may now have btree indexes built on them, and they
    may be included in ORDER BY and DISTINCT clauses.

6. New array handling functions:
    array_append  (anyarray, anyelement) returns anyarray
      append an element to the end of an array
    array_cat (anyarray, anyarray) returns anyarray
      concatenate two arrays
    array_lower (anyarray, integer) returns integer
      returns lower bound of the requested array dimension
    array_prepend (anyelement, anyarray) returns anyarray
      append an element to the beginning of an array
    array_to_string (anyarray, text) returns text
      concatenates array elements using provided delimiter
    array_upper (anyarray, integer) returns integer
      returns upper bound of the requested array dimension
    string_to_array (text, text) returns text[]
      splits string into array elements using provided delimiter

7. expression operator ANY|SOME|ALL (array expression):
    The right-hand side is a parenthesized expression, which must yield
    an array value. The left-hand expression is evaluated and compared
    to each element of the array using the given operator, which must
    yield a Boolean result.
      - The result of ANY is "true" if any true result is obtained. The
        result is "false" if no true result is found (including the
        special case where the array has zero elements).
      - SOME is a synonym for ANY.
      - The result of ALL is "true" if all comparisons yield true
        (including the special case where the array has zero elements).
         The result is "false" if any false result is found.

8. empty array element and slice assignment:
    It is now possible to add an element to an empty array via array
    element assignment, or add multiple array elements to an empty array
    via the array slice syntax. Example:

      create table t (f1 int, f2 int[]);
      insert into t values(1,'{}');
      update t set f2[2][4][6] = 42 where f1 = 1;
      insert into t values(2,'{}');
      update t set f2[2:4] = ARRAY[42,43,44] where f1 = 2;
      regression=# select * from t;
       f1 |     f2
      ----+------------
        1 | {{{42}}}
        2 | {42,43,44}
      (2 rows)


pgsql-advocacy by date:

Previous
From: Josh Berkus
Date:
Subject: Re: [GENERAL] MySQL gets $19.5 MM
Next
From: Martin Sarsale
Date:
Subject: replication: PG vs My