1. 05 11月, 2015 6 次提交
    • H
      Error on "SET optimizer=on" if server is built without ORCA. · 0ac120aa
      Heikki Linnakangas 提交于
      Also, rephrase the message you get from enable_xform() etc. functions, if
      the server has been built without ORCA.
      
      Add alternative expected output files to make the regression tests pass
      without --enable-orca.
      0ac120aa
    • H
      Fix --without-libcurl build. · 1fc01f37
      Heikki Linnakangas 提交于
      The readable_external_table_timeout global variable is needed even when
      building without libcurl, because the GUC still exists and is listed in
      guc.c, even though doesn't do anything without libcurl support. Move it
      outside the #ifdef USE_CURL block.
      
      While we're at it, silence a few  "<function> defined but not used"
      warnings from sendalert.c. Some static functions were only called when
      compiling with libcurl, so put them inside #ifdef LIBCURL blocks to silence
      the warnings.
      
      Reported by Digoal.zhou.
      1fc01f37
    • H
    • H
      Remove useless 'initdb' bugbuster test · b80a01e9
      Heikki Linnakangas 提交于
      b80a01e9
    • H
      Add 'Partition by' description in psql · 57e5784d
      Haisheng Yuan 提交于
      When user runs \d or \d+ on a partition table, it will display partition
      keys on the current level for the partition table with the clause of
      'Partition by: (partition_key_1, ..., partition_key_n)' after
      'Distributed by' clause. But if user runs \d or \d+ on a non-partition
      table or leaf level partition table, the 'Partition by' clause will not
      be displayed.
      
      Haisheng Yuan
      Closes #25
      57e5784d
    • A
      Concurrent drop should not report error for drop IF EXISTS. · 8ff2e195
      Ashwin Agrawal 提交于
      Relation can potential be dropped while waiting to acquire lock.
      If cannot find the relation for "if_exists" case should just emit
      NOTICE and act as noop.
      8ff2e195
  2. 04 11月, 2015 1 次提交
  3. 03 11月, 2015 10 次提交
    • A
      Align Drop on segments to actual user command. · dab24af8
      Ashwin Agrawal 提交于
      Drop on segments was performed always using if exists,
      this may cause inconsistency in cluster if for some reason table is
      found on master but misses to find on segments. Patch now dispatchs DROP
      with 'if_exists' only when it's specified by user. Otherwise, segments
      will abort the transaction if the table being dropped is not found,
      instead of just dropping table only on master.
      dab24af8
    • A
      Avoid SIGSEGV caused by logging an error in walsender. · 5b0d517b
      Abhijit Subramanya 提交于
      The issue was manifested by having large file in data directory.
      gpinitstandby encountered SIGSEGV as tar fails during basebackup.
      With the fix it gracefully errors out.
      Patch pulls in following commit from upstream in order to improve
      error handling and recovery in walsenders.
      	commit fd5942c1
      	Author: Heikki Linnakangas <heikki.linnakangas@iki.fi>
      	Date:   Fri Oct 5 17:13:07 2012 +0300
      
      	Use the regular main processing loop also in walsenders.
      
      	The regular backend's main loop handles signal handling and error
      	recovery better than the current WAL sender command loop does. For example,
      	if the client hangs and a SIGTERM is received before starting streaming, the
      	walsender will now terminate immediately, rather than hang until the connection times out.
      5b0d517b
    • A
      DROP TABLE should look up the name again, if blocked. · 4739cd22
      Asim Praveen 提交于
      If DROP has to wait for a lock on the relation after its OID was looked up, it
      may happen that the name is no longer valid by the time DROP acquires the lock.
      
      This case is handled by pulling a function from upstream commit
      	commit 4240e429
      	Author: Robert Haas <rhaas@postgresql.org>
      	Date:   Fri Jul 8 22:19:30 2011 -0400
      	Try to acquire relation locks in RangeVarGetRelid.
      4739cd22
    • A
      Fix block size calculation for CO in case of RLE. · e0da8811
      Ashwin Agrawal 提交于
      The patch adds size required to finalize the rle repeats array size
      to the block space calculation for CO, to correctly detect if current
      block is full and should start new block for current item.
      
      If its non-repeated item (NULL / value), need to finalize the rle
      repeats counts array and then store new value. Space calculation only
      checked for space required for new item either in NULLs array or actual
      item space, but missed that to store the item which is non-repeating,
      would have to finalize the previous repeating array which would need 4 bytes
      of space along with it. Hence said okay to store the item but later caused
      failure to insert when pushing the block to disk as its over
      blocksize specified for the table.
      e0da8811
    • H
      Disable last remnants of the ancient V0-style C function support. · 2c1b3761
      Heikki Linnakangas 提交于
      It was not working correctly anyway on 32-bit x86 systems, where
      sizeof(int) < sizeof(Datum), because in Greenplum sizeof(Datum) == 8
      even on 32-bit platforms. This was revealed by failures on the 'misc'
      regression test, which tested this the V0 support.
      2c1b3761
    • H
      Avoid clashing with another test that creates table 'sales' · 4c098b92
      Heikki Linnakangas 提交于
      The 'gp_optimizer' test also creates a table called 'sales', which started
      to clash with the 'sales' table created by the new 'decode_expr' test.
      Rename the test table used in decode_expr, and also drop it at the end of
      the test.
      4c098b92
    • H
      Silence failure in 'misc' test case when ORCA is enabled. · 2a8e85a0
      Heikki Linnakangas 提交于
      Not sure why ORCA causes the error, but it seems to be intended behaviour,
      so I'm not going to try fixing that right now.
      2a8e85a0
    • H
      Move gphdfs regression test from server's test suite to gphdfs. · ceb25d9f
      Heikki Linnakangas 提交于
      The gphdfs test was concerned with testing gphdfs. It's useless without
      gphdfs itself, and was causing the main regression suite to fail, if gphdfs
      was not installed. Likewise, move the gphdfs-related parts of exttab1 test.
      ceb25d9f
    • H
      Move tests for DECODE() from bugbuster to main test suite. · fa2cb8cf
      Heikki Linnakangas 提交于
      Looks like all the 'functional' test was testing was DECODE() expressions,
      so rename the test, and move it to the main test suite. While we're at it,
      clean up the test case to some extent. Fix the missing semicolons from some
      queries, which caused the subsequent DROP to fail. Remove unused functions
      and emp and dept tables. Add some comments explaining what each test does.
      Remove use of multi-byte characters from test case, so that it works
      regardless of encoding.
      fa2cb8cf
    • H
      Fix and re-enable 'misc' regression test. · 5b3b528c
      Heikki Linnakangas 提交于
      Remove unnecessary ORDER BY clauses that are not present in the upstream
      version. Disable COPY BINARY test, as GPDB doesn't support BINARY copy.
      Finally, adjust the error messages in the expected output to match what
      you get nowadays.
      
      DROP TABLE cleanup commands have been added to some other tests, so that
      the extra user tables don't appear in the output of the 'misc' test. It's
      not very nice of the 'misc' test to list all user tables, but this
      nevertheless seems less likely to cause merge conflicts than ripping out
      that part of the test altogether. There are still differences in the list
      of user tables though.
      5b3b528c
  4. 02 11月, 2015 7 次提交
    • H
      Fix and re-enable 'copy2' regression test. · 91d772b8
      Heikki Linnakangas 提交于
      Revert some unnecessary changes compared to upstream: there's no need for
      ORDER BYs in queries, gpdiff.pl will mask out row order differences. That
      needed some fixes to atmsort.pl though, to make it smarter about reordering
      COPY TO STDOUT results. It used to only deal with the COPY (SELECT ...) TO
      STDOUT variant, and particularly named tables (COPY .*test1 TO STDOUT). Make
      it handle all COPY TO STDOUT commands. Also make it smarter about detecting
      the end of COPY TO STDOUT output. In addition to -- or ERROR, also treat any
      SELECT, UPDATE, CREATE etc. command as the end of result. In the passing,
      remove the "-- copy_stdout" command from atmsort.pl, as it was unused.
      
      No need to label the functions as immutable or with NO SQL or MODIFIES SQL
      DATA, and update the error message in the expected output about
      cross-segment access within functions.
      
      One of the tests gives a different error than on upstream: an empty line
      gives "invalid integer" error in upstream, but "missing data" on GPDB. I'm
      not quite sure what's causing that, but both errors seem reasonable for that
      case (the "missing data" is perhaps even better), so let's just memorize
      that difference.
      91d772b8
    • H
      Honor FORCE QUOTE in dispatched copy mode. · 7fe3a25e
      Heikki Linnakangas 提交于
      The upstream 'copy2' regression test exercised this, but we haven't noticed
      because we've disabled that test. I spotted this while trying to re-enable
      it. Nevertheless, let's add an explicit test for this.
      7fe3a25e
    • H
      Fix FORCE QUOTE for integers and numerics. · e8ad74ea
      Heikki Linnakangas 提交于
      Integers and numerics don't need quoting in CSV-format COPY, but they should
      still be quoted if the FORCE QUOTE option is used.
      
      We had memorized the incorrect output as expected output of the GPDB-added
      parts at the end of the 'copy' regression test. Fix that, but also add
      an explicit test case for this.
      e8ad74ea
    • H
      Remove unused --enable-forceplan configure option · 56a8eb3e
      Heikki Linnakangas 提交于
      The USE_FORCE_PLAN option has been unused for a long time.
      56a8eb3e
    • H
      Mask out difference in exttab1 test output. · f9024427
      Heikki Linnakangas 提交于
      The shell on my laptop produces an error like:
      
      ERROR:  external table ext_stderr1 command ended with error. sh: 1: ...
      
      while the expected output is:
      
      ERROR:  external table ext_stderr1 command ended with error. sh: ...
      
      (Note the missing line number, "1: ").
      
      Add a substitution pattern to the test case to mask that out. There was
      already a similar pattern for shells that print "line 1:".
      f9024427
    • H
      Move bitmapscan bugbuster test to main suite, and clean it up. · 7d1e90d2
      Heikki Linnakangas 提交于
      Many of the test queries were doubled: run first within an ignore-block,
      and then for real. That seems pointless, so remove the duplicates. Also,
      fix typos in comments.
      
      This hopefully fixes test failures that we've occasionally seen in the
      buildfarm, where the mechanism in gpdiff.pl that masks out result set
      ordering differences gets confused by the duplicated queries in the
      ignore-blocks.
      7d1e90d2
    • H
      Fix issue #27, build problem on CentOS 7, with --with-plperl. · f493756a
      Heikki Linnakangas 提交于
      See earlier discussion on this on pgsql-hackers, message-id
      9B946296-A2EB-4B45-A190-153F06662F8B@kineticode.com. We'd get this fix
      eventually as we merge with later PostgreSQL versions, but let's make life
      easier for people hitting this issue now.
      
      This is a backpatch of the following upstream commit, sans the MSVC build
      parts, as I have no environment to test that and we don't support Windows
      anyway. We'll get the MSVC parts later, as we merge.
      
      commit ba00ab0b
      Author: Andrew Dunstan <andrew@dunslane.net>
      Date:   Sat Nov 26 15:22:32 2011 -0500
      
          Use the preferred version of xsubpp, not necessarily the one that came with the
          distro version of perl.
      
          David Wheeler and Alex Hunsaker.
      
          Backpatch to 9.1 where it applies cleanly. A simple workaround is available for earlier
          branches, and further effort doesn't seem warranted.
      f493756a
  5. 30 10月, 2015 1 次提交
  6. 29 10月, 2015 1 次提交
  7. 28 10月, 2015 3 次提交
    • H
      Add generated files to .gitignores · 6d122bcd
      Heikki Linnakangas 提交于
      Based on patch by Raymond Barbiero
      6d122bcd
    • H
      Remove -Werror, replace with more specific -Wno-* options. · 0675ad72
      Heikki Linnakangas 提交于
      It's important to pay attention to compiler warnings, but -Werror isn't
      buying us much at the moment. Firstly, there are a lot of warnings on modern
      versions of gcc. I have to pass: "-Wno-error=unused-but-set-variable
      -Wno-error=enum-compare -Wno-error=address -Wno-error=maybe-uninitialized"
      to make it compile. More important than erroring out on warnings is to make
      sure there are no warnings to begin with. Once we get to that state, any
      warnings will stick out like sore thumb anyway, and you won't need -Werror
      to make them more annoying.
      
      We have a long way until we are 100% warning free, but most of the warnings
      come from upstream code. They have been fixed in later versions of
      PostgreSQL, so they will go away as we merge with upstream.
      0675ad72
    • I
      Import Greenplum source code. · 6b0e52be
      Initial Greenplum code dump 提交于
      6b0e52be
  8. 02 12月, 2006 3 次提交
  9. 01 12月, 2006 2 次提交
    • T
      Minor adjustments to make failures in startup/shutdown behave more cleanly. · 5f60086e
      Tom Lane 提交于
      StartupXLOG and ShutdownXLOG no longer need to be critical sections, because
      in all contexts where they are invoked, elog(ERROR) would be translated to
      elog(FATAL) anyway.  (One change in bgwriter.c is needed to make this true:
      set ExitOnAnyError before trying to exit.  This is a good fix anyway since
      the existing code would have gone into an infinite loop on elog(ERROR) during
      shutdown.)  That avoids a misleading report of PANIC during semi-orderly
      failures.  Modify the postmaster to include the startup process in the set of
      processes that get SIGTERM when a fast shutdown is requested, and also fix it
      to not try to restart the bgwriter if the bgwriter fails while trying to write
      the shutdown checkpoint.  Net result is that "pg_ctl stop -m fast" does
      something reasonable for a system in warm standby mode, and so should Unix
      system shutdown (ie, universal SIGTERM).  Per gripe from Stephen Harris and
      some corner-case testing of my own.
      5f60086e
    • T
      Fix bug with page deletion. If inner page is removed and it tries to · ef148d6b
      Teodor Sigaev 提交于
      remove page on next level linked from next inner page, ginScanToDelete()
      wrongly sets parent page. Bug reveals when many item pointers from index
      was deleted ( several hundred thousands).
      
      Bug is discovered by hubert depesz lubaczewski <depesz@gmail.com>
      
      Suppose, we need rc2 before release...
      ef148d6b
  10. 30 11月, 2006 2 次提交
  11. 29 11月, 2006 3 次提交
    • P
      Spelling fix · 0943799f
      Peter Eisentraut 提交于
      0943799f
    • T
      Update timezone data to tzdata2006p zic distribution. It seems Western · 765cc158
      Tom Lane 提交于
      Australia decided to institute DST with one month's notice ... way to go,
      politicians.
      765cc158
    • T
      Mark to_char(timestamp without timezone) as stable, not immutable, since its · 64353640
      Tom Lane 提交于
      result now depends on the lc_messages setting, as noted by Bruce.
      Also, mark to_number() and the numeric-type variants of to_char() as stable,
      because their results depend on lc_numeric; this is a longstanding oversight.
      Also, mark to_date() and to_char(interval) as stable; although these appear
      not to depend on any GUC variables as of CVS HEAD, that seems a property
      unlikely to survive future improvements.  It seems best to mark all the
      formatting functions stable and be done with it.
      catversion not bumped, because this does not seem critical enough to force
      a post-RC1 initdb, and anyway we cannot do so in the back branches.
      64353640
  12. 28 11月, 2006 1 次提交