Skip to content
Snippets Groups Projects
Select Git revision
  • benchmark-tools
  • postgres-lambda
  • master default
  • REL9_4_25
  • REL9_5_20
  • REL9_6_16
  • REL_10_11
  • REL_11_6
  • REL_12_1
  • REL_12_0
  • REL_12_RC1
  • REL_12_BETA4
  • REL9_4_24
  • REL9_5_19
  • REL9_6_15
  • REL_10_10
  • REL_11_5
  • REL_12_BETA3
  • REL9_4_23
  • REL9_5_18
  • REL9_6_14
  • REL_10_9
  • REL_11_4
23 results

postgres-lambda-diff

  • Clone with SSH
  • Clone with HTTPS
  • user avatar
    Tom Lane authored
    1. If there is exactly one pg_operator entry of the right name and oprkind,
    oper() and related routines would return that entry whether its input type
    had anything to do with the request or not.  This is just premature
    optimization: we shouldn't return the single candidate until after we verify
    that it really is a valid candidate, ie, is at least coercion-compatible
    with the given types.
    
    2. oper() and related routines only promise a coercion-compatible result.
    Unfortunately, there were quite a few callers that assumed the returned
    operator is binary-compatible with the given datatype; they would proceed
    to call it without making any datatype coercions.  These callers include
    sorting, grouping, aggregation, and VACUUM ANALYZE.  In general I think
    it is appropriate for these callers to require an exact or binary-compatible
    match, so I've added a new routine compatible_oper() that only succeeds if
    it can find an operator that doesn't require any run-time conversions.
    Callers now call oper() or compatible_oper() depending on whether they are
    prepared to deal with type conversion or not.
    
    The upshot of these bugs is revealed by the following silliness in PL/Tcl's
    selftest: it creates an operator @< on int4, and then tries to use it to
    sort a char(N) column.  The system would let it do that :-( (and evidently
    has done so since 6.3 :-( :-().  The result in this case was just a silly
    sort order, but the reverse combination would've provoked coredump from
    trying to dereference integers.  With this fix you get more reasonable
    behavior:
    pltcl_test=# select * from T_pkey1 order by key1, key2 using @<;
    ERROR:  Unable to identify an operator '@<' for types 'bpchar' and 'bpchar'
            You will have to retype this query using an explicit cast
    13cc7eb3
    History
    PostgreSQL Data Base Management System (formerly known as Postgres, then
    as Postgres95).
      
    This directory contains the development version of 7.1 of the
    PostgreSQL database server.  The server is not ANSI SQL compliant, but
    it gets closer with every release.  After you unzip and untar the
    distribution file, look at file INSTALL for the installation notes and
    file HISTORY for the changes.
    
    The latest version of this software may be obtained at
    ftp://ftp.postgresql.org/pub/.  For more information look at our WWW
    home page located at http://www.postgreSQL.org/.
    
    PostgreSQL is not public domain software.  It is copyrighted by the
    University of California but may be used according to the licensing
    terms of the the copyright below:
    
    ------------------------------------------------------------------------
    
    POSTGRES95 Data Base Management System (formerly known as Postgres, then
    as Postgres95).
    
    Copyright (c) 1994-7 Regents of the University of California
    
    Permission to use, copy, modify, and distribute this software and its
    documentation for any purpose, without fee, and without a written agreement
    is hereby granted, provided that the above copyright notice and this
    paragraph and the following two paragraphs appear in all copies.
    
    IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR
    DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, INCLUDING
    LOST PROFITS, ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS
    DOCUMENTATION, EVEN IF THE UNIVERSITY OF CALIFORNIA HAS BEEN ADVISED OF THE
    POSSIBILITY OF SUCH DAMAGE.
    
    THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES,
    INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
    AND FITNESS FOR A PARTICULAR PURPOSE.  THE SOFTWARE PROVIDED HEREUNDER IS
    ON AN "AS IS" BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO OBLIGATIONS TO
    PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.