1. 04 Apr, 2008 6 commits
  2. 03 Apr, 2008 9 commits
  3. 02 Apr, 2008 3 commits
    • Tom Lane's avatar
      Revert my bad decision of about a year ago to make PortalDefineQuery · 1591fcbe
      Tom Lane authored
      responsible for copying the query string into the new Portal.  Such copying
      is unnecessary in the common code path through exec_simple_query, and in
      this case it can be enormously expensive because the string might contain
      a large number of individual commands; we were copying the entire, long
      string for each command, resulting in O(N^2) behavior for N commands.
      (This is the cause of bug #4079.)  A second problem with it is that
      PortalDefineQuery really can't risk error, because if it elog's before
      having set up the Portal, we will leak the plancache refcount that the
      caller is trying to hand off to the portal.  So go back to the design in
      which the caller is responsible for making sure everything is copied into
      the portal if necessary.
      1591fcbe
    • Magnus Hagander's avatar
      Convert three more guc settings to enum type: · ad6bf716
      Magnus Hagander authored
      default_transaction_isolation, session_replication_role and regex_flavor.
      ad6bf716
    • Bruce Momjian's avatar
      Remove due to survey/discussion: · afa2a9ec
      Bruce Momjian authored
      <
      < * Prefix command-line utilities like createuser with 'pg_'
      <
      <   http://archives.postgresql.org/pgsql-hackers/2007-06/msg00025.php
      <
      afa2a9ec
  4. 01 Apr, 2008 3 commits
    • Tom Lane's avatar
      Support EXECUTE USING in plpgsql. · e2a88043
      Tom Lane authored
      Pavel Stehule, with some improvements by myself.
      e2a88043
    • Tom Lane's avatar
      Add SPI-level support for executing SQL commands with one-time-use plans, · d5466e38
      Tom Lane authored
      that is commands that have out-of-line parameters but the plan is prepared
      assuming that the parameter values are constants.  This is needed for the
      plpgsql EXECUTE USING patch, but will probably have use elsewhere.
      
      This commit includes the SPI functions and documentation, but no callers
      nor regression tests.  The upcoming EXECUTE USING patch will provide
      regression-test coverage.  I thought committing this separately made
      sense since it's logically a distinct feature.
      d5466e38
    • Tom Lane's avatar
      Fix an oversight I made in a cleanup patch over a year ago: · 6b73d7e5
      Tom Lane authored
      eval_const_expressions needs to be passed the PlannerInfo ("root") structure,
      because in some cases we want it to substitute values for Param nodes.
      (So "constant" is not so constant as all that ...)  This mistake partially
      disabled optimization of unnamed extended-Query statements in 8.3: in
      particular the LIKE-to-indexscan optimization would never be applied if the
      LIKE pattern was passed as a parameter, and constraint exclusion depending
      on a parameter value didn't work either.
      6b73d7e5
  5. 31 Mar, 2008 4 commits
    • Tom Lane's avatar
      Apply my original fix for Taiki Yamaguchi's bug report about DISTINCT MAX(). · d3441155
      Tom Lane authored
      Add some regression tests for plausible failures in this area.
      d3441155
    • Tom Lane's avatar
      Fix my brain fade in TRUNCATE triggers patch: can't release relcache refcounts · e86237ff
      Tom Lane authored
      while EState still contains pointers to those relations.  Exposed by the
      CLOBBER_CACHE_ALWAYS tests that buildfarm member jaguar is running (I knew
      those cycles would pay off...)
      e86237ff
    • Tom Lane's avatar
      Use error message wordings for permissions checks on .pgpass and SSL private · 3405f2b9
      Tom Lane authored
      key files that are similar to the one for the postmaster's data directory
      permissions check.  (I chose to standardize on that one since it's the most
      heavily used and presumably best-wordsmithed by now.)  Also eliminate explicit
      tests on file ownership in these places, since the ensuing read attempt must
      fail anyway if it's wrong, and there seems no value in issuing the same error
      message for distinct problems.  (But I left in the explicit ownership test in
      postmaster.c, since it had its own error message anyway.)  Also be more
      specific in the documentation's descriptions of these checks.  Per a gripe
      from Kevin Hunter.
      3405f2b9
    • Tom Lane's avatar
      Fix a number of places that were making file-type tests infelicitously. · c5f11f9d
      Tom Lane authored
      The places that did, eg,
      	(statbuf.st_mode & S_IFMT) == S_IFDIR
      were correct, but there is no good reason not to use S_ISDIR() instead,
      especially when that's what the other 90% of our code does.  The places
      that did, eg,
      	(statbuf.st_mode & S_IFDIR)
      were flat out *wrong* and would fail in various platform-specific ways,
      eg a symlink could be mistaken for a regular file on most Unixen.
      
      The actual impact of this is probably small, since the problem cases
      seem to always involve symlinks or sockets, which are unlikely to be
      found in the directories that PG code might be scanning.  But it's
      clearly trouble waiting to happen, so patch all the way back anyway.
      (There seem to be no occurrences of the mistake in 7.4.)
      c5f11f9d
  6. 30 Mar, 2008 3 commits
  7. 29 Mar, 2008 3 commits
  8. 28 Mar, 2008 6 commits
  9. 27 Mar, 2008 3 commits