1. 26 Nov, 2007 2 commits
    • Tom Lane's avatar
      Fix select_common_type() so that it can select a domain type, if all inputs · 07daff63
      Tom Lane authored
      to a UNION, CASE, or related construct are of the same domain type.  The
      main part of this routine smashes domains to their base types, which seems
      necessary because the logic involves TypeCategory() and IsPreferredType(),
      neither of which work usefully on domains.  However, we can add a first
      pass that just detects whether all the inputs are exactly the same type,
      and if so accept that without question (so long as it's not UNKNOWN).
      Per recent gripe from Dean Rasheed.
      
      In passing, remove some tests for InvalidOid, which have clearly been dead
      code for quite some time now, because getBaseType() would fail on that input.
      
      Also, clarify the manual's not-very-precise description of the existing
      algorithm's behavior.
      07daff63
    • Peter Eisentraut's avatar
  2. 25 Nov, 2007 4 commits
  3. 24 Nov, 2007 13 commits
  4. 23 Nov, 2007 5 commits
    • Tom Lane's avatar
      Avoid uselessly building a duplicate of the original clause in trivial cases · 92c0bf09
      Tom Lane authored
      where the EquivalenceClass machinery is unable to deduce anything more from a
      simple "var = const" qual clause.  There are probably some more cases where
      this could be done, but this seems to take care of most of the added overhead
      for simple queries.  Per gripe from Guillaume Smet.
      
      In passing, fix a problem that was exposed by this change:
      reconsider_outer_join_clause and friends were passing the wrong relids to
      build_implied_join_equality, resulting in RestrictInfos with the wrong
      required_relids.  This mistake was masked in typical cases since the bogus
      RestrictInfos would never have escaped from the EquivalenceClass machinery,
      but I think there might be corner cases involving "broken" ECs where there
      would have been a visible failure even without the new optimization.  In any
      case the code was certainly not operating as intended.
      92c0bf09
    • Bruce Momjian's avatar
      Fix white space in MONEY type code. Rename 'comma' to more generic · 335d9aff
      Bruce Momjian authored
      'ssymbol' as used in previous function.
      335d9aff
    • Bruce Momjian's avatar
      Update text: · ba2b2a2c
      Bruce Momjian authored
      < * Prevent long-lived temporary tables from causing frozen-Xid advancement
      > * Prevent long-lived temporary tables from causing frozen-xid advancement
      >
      >    The problem is that autovacuum cannot vacuum them to set frozen xids;
      >    only the session that created them can do that.
      >
      >
      >
      ba2b2a2c
    • Alvaro Herrera's avatar
      Fix buggy usage of vsnprintf in PL/Python by removing it altogether, instead · 558c9270
      Alvaro Herrera authored
      relying on stringinfo.c.  This fixes a problem reported by Marko Kreen, but I
      didn't use his patch, per subsequent discussion.
      558c9270
    • Tatsuo Ishii's avatar
      d8e8a495
  5. 22 Nov, 2007 6 commits
  6. 21 Nov, 2007 5 commits
  7. 20 Nov, 2007 5 commits