1. 17 5月, 2013 1 次提交
  2. 04 3月, 2013 1 次提交
    • T
      Get rid of any toast table when converting a table to a view. · b15a6da2
      Tom Lane 提交于
      Also make sure other fields of the view's pg_class entry are appropriate
      for a view; it shouldn't have relfrozenxid set for instance.
      
      This ancient omission isn't believed to have any serious consequences in
      versions 8.4-9.2, so no backpatch.  But let's fix it before it does bite
      us in some serious way.  It's just luck that the case doesn't cause
      problems for autovacuum.  (It did cause problems in 8.3, but that's out
      of support.)
      
      Andres Freund
      b15a6da2
  3. 09 2月, 2013 1 次提交
  4. 25 10月, 2012 1 次提交
    • T
      When converting a table to a view, remove its system columns. · a4e8680a
      Tom Lane 提交于
      Views should not have any pg_attribute entries for system columns.
      However, we forgot to remove such entries when converting a table to a
      view.  This could lead to crashes later on, if someone attempted to
      reference such a column, as reported by Kohei KaiGai.
      
      Patch in HEAD only.  This bug has been there forever, but in the back
      branches we will have to defend against existing mis-converted views,
      so it doesn't seem worthwhile to change the conversion code too.
      a4e8680a
  5. 20 8月, 2012 2 次提交
  6. 20 2月, 2012 1 次提交
    • A
      Improve pretty printing of viewdefs. · 2f582f76
      Andrew Dunstan 提交于
      Some line feeds are added to target lists and from lists to make
      them more readable. By default they wrap at 80 columns if possible,
      but the wrap column is also selectable - if 0 it wraps after every
      item.
      
      Andrew Dunstan, reviewed by Hitoshi Harada.
      2f582f76
  7. 24 11月, 2010 1 次提交
  8. 22 9月, 2009 1 次提交
  9. 19 1月, 2009 1 次提交
  10. 27 5月, 2007 1 次提交
    • T
      Repair two constraint-exclusion corner cases triggered by proving that an · cadb7833
      Tom Lane 提交于
      inheritance child of an UPDATE/DELETE target relation can be excluded by
      constraints.  I had rearranged some code in set_append_rel_pathlist() to
      avoid "useless" work when a child is excluded, but overdid it and left
      the child with no cheapest_path entry, causing possible failure later
      if the appendrel was involved in a join.  Also, it seems that the dummy
      plan generated by inheritance_planner() when all branches are excluded
      has to be a bit less dummy now than was required in 8.2.
      Per report from Jan Wieck.  Add his test case to the regression tests.
      cadb7833
  11. 28 2月, 2006 1 次提交
  12. 07 4月, 2005 1 次提交
    • N
      Add a "USING" clause to DELETE, which is equivalent to the FROM clause · f5ab0a14
      Neil Conway 提交于
      in UPDATE. We also now issue a NOTICE if a query has _any_ implicit
      range table entries -- in the past, we would only warn about implicit
      RTEs in SELECTs with at least one explicit RTE.
      
      As a result of the warning change, 25 of the regression tests had to
      be updated. I also took the opportunity to remove some bogus whitespace
      differences between some of the float4 and float8 variants. I believe
      I have correctly updated all the platform-specific variants, but let
      me know if that's not the case.
      
      Original patch for DELETE ... USING from Euler Taveira de Oliveira,
      reworked by Neil Conway.
      f5ab0a14
  13. 26 3月, 2005 1 次提交
  14. 03 10月, 2004 1 次提交
  15. 09 3月, 2004 1 次提交
  16. 22 11月, 2003 1 次提交
    • T
      COMMENT ON casts, conversions, languages, operator classes, and · 42ce74bf
      Tom Lane 提交于
      large objects.  Dump all these in pg_dump; also add code to pg_dump
      user-defined conversions.  Make psql's large object code rely on
      the backend for inserting/deleting LOB comments, instead of trying to
      hack pg_description directly.  Documentation and regression tests added.
      
      Christopher Kings-Lynne, code reviewed by Tom
      42ce74bf
  17. 31 10月, 2003 1 次提交
  18. 14 12月, 2002 1 次提交
  19. 22 11月, 2002 1 次提交
  20. 21 11月, 2002 1 次提交
  21. 20 10月, 2002 1 次提交
    • T
      Fix rewrite code so that rules are in fact executed in order by name, · c1f91a38
      Tom Lane 提交于
      rather than being reordered according to INSTEAD attribute for
      implementation convenience.
      Also, increase compiled-in recursion depth limit from 10 to 100 rewrite
      cycles.  10 seems pretty marginal for situations where multiple rules
      exist for the same query.  There was a complaint about this recently,
      so I'm going to bump it up.  (Perhaps we should make the limit a GUC
      parameter, but that's too close to being a new feature to do in beta.)
      c1f91a38
  22. 02 9月, 2002 2 次提交
  23. 03 5月, 2002 1 次提交
    • T
      Retire xlateSqlType/xlateSqlFunc; all type name translations are now · 53cedcac
      Tom Lane 提交于
      handled as special productions.  This is needed to keep us honest about
      user-schema type names that happen to coincide with system type names.
      Per pghackers discussion 24-Apr.  To avoid bloating the keyword list
      too much, I removed the translations for datetime, timespan, and lztext,
      all of which were slated for destruction several versions back anyway.
      53cedcac
  24. 19 4月, 2002 1 次提交
    • T
      Rule names are now unique per-relation, rather than unique globally. · b3120804
      Tom Lane 提交于
      DROP RULE and COMMENT ON RULE syntax adds an 'ON tablename' clause,
      similar to TRIGGER syntaxes.  To allow loading of existing pg_dump
      files containing COMMENT ON RULE, the COMMENT code will still accept
      the old syntax --- but only if the target rulename is unique across
      the whole database.
      b3120804
  25. 12 4月, 2002 1 次提交
    • T
      Restructure representation of aggregate functions so that they have pg_proc · 902a6a0a
      Tom Lane 提交于
      entries, per pghackers discussion.  This fixes aggregates to live in
      namespaces, and also simplifies/speeds up lookup in parse_func.c.
      Also, add a 'proimplicit' flag to pg_proc that controls whether a type
      coercion function may be invoked implicitly, or only explicitly.  The
      current settings of these flags are more permissive than I would like,
      but we will need to debate and refine the behavior; for now, I avoided
      breaking regression tests as much as I could.
      902a6a0a
  26. 15 8月, 2001 1 次提交
    • T
      sum() on int2 and int4 columns now uses an int8, not numeric, accumulator · 5f7c2bdb
      Tom Lane 提交于
      for speed reasons; its result type also changes to int8.  avg() on these
      datatypes now accumulates the running sum in int8 for speed; but we still
      deliver the final result as numeric, so that fractional accuracy is
      preserved.
      
      count() now counts and returns in int8, not int4.  I am a little nervous
      about this possibly breaking users' code, but there didn't seem to be
      a strong sentiment for avoiding the problem.  If we get complaints during
      beta, we can change count back to int4 and add a "count8" aggregate.
      For that matter, users can do it for themselves with a simple CREATE
      AGGREGATE command; the int4inc function is still present, so no C hacking
      is needed.
      
      Also added max() and min() aggregates for OID that do proper unsigned
      comparison, instead of piggybacking on int4 aggregates.
      
      initdb forced.
      5f7c2bdb
  27. 10 7月, 2001 1 次提交
  28. 06 12月, 2000 1 次提交
  29. 13 9月, 2000 1 次提交
  30. 20 4月, 2000 1 次提交
  31. 06 1月, 2000 1 次提交
  32. 01 8月, 1999 1 次提交
  33. 17 5月, 1999 1 次提交
  34. 13 5月, 1999 1 次提交
  35. 15 4月, 1999 1 次提交
    • T
      Add ORDER BY clauses to some select-from-view operations · dbce02f1
      Tom Lane 提交于
      in rules regression test, in order to eliminate bogus test 'failures'
      that occur due to platform-dependent and join-implementation-dependent
      ordering of tuples.  I'm not sure that I got all of the SELECTs that need
      ordering clauses --- we may need some more.  But this takes care of the
      diffs between my platform and Jan's.
      dbce02f1
  36. 23 2月, 1999 1 次提交
  37. 08 2月, 1999 2 次提交