1. 20 Jul, 2003 1 commit
  2. 17 Jul, 2003 1 commit
  3. 04 Jul, 2003 1 commit
  4. 27 Jun, 2003 1 commit
  5. 10 Mar, 2003 1 commit
  6. 09 Oct, 2002 1 commit
  7. 04 Sep, 2002 1 commit
  8. 02 Sep, 2002 1 commit
    • Tom Lane's avatar
      Code review for HeapTupleHeader changes. Add version number to page headers · c7a165ad
      Tom Lane authored
      (overlaying low byte of page size) and add HEAP_HASOID bit to t_infomask,
      per earlier discussion.  Simplify scheme for overlaying fields in tuple
      header (no need for cmax to live in more than one place).  Don't try to
      clear infomask status bits in tqual.c --- not safe to do it there.  Don't
      try to force output table of a SELECT INTO to have OIDs, either.  Get rid
      of unnecessarily complex three-state scheme for TupleDesc.tdhasoids, which
      has already caused one recent failure.  Improve documentation.
      c7a165ad
  9. 29 Aug, 2002 1 commit
  10. 22 Aug, 2002 1 commit
  11. 09 Aug, 2002 1 commit
    • Tom Lane's avatar
      has_table_privilege spawns scions has_database_privilege, has_function_privilege, · 4ab8e690
      Tom Lane authored
      has_language_privilege, has_schema_privilege to let SQL queries test
      all the new privilege types in 7.3.  Also, add functions pg_table_is_visible,
      pg_type_is_visible, pg_function_is_visible, pg_operator_is_visible,
      pg_opclass_is_visible to test whether objects contained in schemas are
      visible in the current search path.  Do some minor cleanup to centralize
      accesses to pg_database, as well.
      4ab8e690
  12. 05 Aug, 2002 1 commit
    • Tom Lane's avatar
      Restructure system-catalog index updating logic. Instead of having · 15fe086f
      Tom Lane authored
      hardwired lists of index names for each catalog, use the relcache's
      mechanism for caching lists of OIDs of indexes of any table.  This
      reduces the common case of updating system catalog indexes to a single
      line, makes it much easier to add a new system index (in fact, you
      can now do so on-the-fly if you want to), and as a nice side benefit
      improves performance a little.  Per recent pghackers discussion.
      15fe086f
  13. 02 Aug, 2002 1 commit
    • Tom Lane's avatar
      ALTER TABLE DROP COLUMN works. Patch by Christopher Kings-Lynne, · 38bb77a5
      Tom Lane authored
      code review by Tom Lane.  Remaining issues: functions that take or
      return tuple types are likely to break if one drops (or adds!)
      a column in the table defining the type.  Need to think about what
      to do here.
      
      Along the way: some code review for recent COPY changes; mark system
      columns attnotnull = true where appropriate, per discussion a month ago.
      38bb77a5
  14. 29 Jul, 2002 1 commit
  15. 20 Jul, 2002 1 commit
    • Bruce Momjian's avatar
      oid is needed, it is added at the end of the struct (after the null · b0f5086e
      Bruce Momjian authored
      bitmap, if present).
      
      Per Tom Lane's suggestion the information whether a tuple has an oid
      or not is carried in the tuple descriptor.  For debugging reasons
      tdhasoid is of type char, not bool.  There are predefined values for
      WITHOID, WITHOUTOID and UNDEFOID.
      
      This patch has been generated against a cvs snapshot from last week
      and I don't expect it to apply cleanly to current sources.  While I
      post it here for public review, I'm working on a new version against a
      current snapshot.  (There's been heavy activity recently; hope to
      catch up some day ...)
      
      This is a long patch;  if it is too hard to swallow, I can provide it
      in smaller pieces:
      
      Part 1:  Accessor macros
      Part 2:  tdhasoid in TupDesc
      Part 3:  Regression test
      Part 4:  Parameter withoid to heap_addheader
      Part 5:  Eliminate t_oid from HeapTupleHeader
      
      Part 2 is the most hairy part because of changes in the executor and
      even in the parser;  the other parts are straightforward.
      
      Up to part 4 the patched postmaster stays binary compatible to
      databases created with an unpatched version.  Part 5 is small (100
      lines) and finally breaks compatibility.
      
      Manfred Koizar
      b0f5086e
  16. 14 Jul, 2002 1 commit
  17. 12 Jul, 2002 1 commit
    • Tom Lane's avatar
      Second phase of committing Rod Taylor's pg_depend/pg_constraint patch. · 7c6df91d
      Tom Lane authored
      pg_relcheck is gone; CHECK, UNIQUE, PRIMARY KEY, and FOREIGN KEY
      constraints all have real live entries in pg_constraint.  pg_depend
      exists, and RESTRICT/CASCADE options work on most kinds of DROP;
      however, pg_depend is not yet very well populated with dependencies.
      (Most of the ones that are present at this point just replace formerly
      hardwired associations, such as the implicit drop of a relation's pg_type
      entry when the relation is dropped.)  Need to add more logic to create
      dependency entries, improve pg_dump to dump constraints in place of
      indexes and triggers, and add some regression tests.
      7c6df91d
  18. 20 Jun, 2002 1 commit
  19. 21 May, 2002 1 commit
    • Tom Lane's avatar
      Remove global variable scanCommandId in favor of storing a command ID · 959e61e9
      Tom Lane authored
      in snapshots, per my proposal of a few days ago.  Also, tweak heapam.c
      routines (heap_insert, heap_update, heap_delete, heap_mark4update) to
      be passed the command ID to use, instead of doing GetCurrentCommandID.
      For catalog updates they'll still get passed current command ID, but
      for updates generated from the main executor they'll get passed the
      command ID saved in the snapshot the query is using.  This should fix
      some corner cases associated with functions and triggers that advance
      current command ID while an outer query is still in progress.
      959e61e9
  20. 20 May, 2002 1 commit
    • Tom Lane's avatar
      Restructure indexscan API (index_beginscan, index_getnext) per · 44fbe20d
      Tom Lane authored
      yesterday's proposal to pghackers.  Also remove unnecessary parameters
      to heap_beginscan, heap_rescan.  I modified pg_proc.h to reflect the
      new numbers of parameters for the AM interface routines, but did not
      force an initdb because nothing actually looks at those fields.
      44fbe20d
  21. 13 May, 2002 1 commit
    • Tom Lane's avatar
      Make operators have their own comments separate from those of the · f69bc37b
      Tom Lane authored
      underlying function; but cause psql's \do to show the underlying
      function's comment if the operator has no comment of its own, to preserve
      the useful functionality of the original behavior.  Also, implement
      COMMENT ON SCHEMA.  Patch from Rod Taylor.
      f69bc37b
  22. 27 Apr, 2002 1 commit
  23. 24 Apr, 2002 1 commit
    • Bruce Momjian's avatar
      Restrict comment to the current database in order to prevent them from · ab117a66
      Bruce Momjian authored
      mysteriously disappearing.
      
      ie.  \d+ will only ever show the comment for the current database --
      which is appropriate since it can only pull comments from the current
      database.
      
      Won't break pgadmin functionality as it enforces this behaviour already.
      
      
      I didn't find any regression tests for COMMENT.
      
      Rod Taylor
      ab117a66
  24. 19 Apr, 2002 1 commit
    • Tom Lane's avatar
      pg_trigger's index on tgrelid is replaced by a unique index on · 20173716
      Tom Lane authored
      (tgrelid, tgname).  This provides an additional check on trigger name
      uniqueness per-table (which was already enforced by the code anyway).
      With this change, RelationBuildTriggers will read the triggers in
      order by tgname, since it's scanning using this index.  Since a
      predictable trigger ordering has been requested for some time, document
      this behavior as a feature.  Also document that rules fire in name
      order, since yesterday's changes to pg_rewrite indexing cause that too.
      20173716
  25. 18 Apr, 2002 1 commit
    • Tom Lane's avatar
      Rule names are now unique per-relation, rather than unique globally. · b3120804
      Tom Lane authored
      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
  26. 16 Apr, 2002 1 commit
    • Tom Lane's avatar
      Operators live in namespaces. CREATE/DROP/COMMENT ON OPERATOR take · 6cef5d25
      Tom Lane authored
      qualified operator names directly, for example CREATE OPERATOR myschema.+
      ( ... ).  To qualify an operator name in an expression you need to write
      OPERATOR(myschema.+) (thanks to Peter for suggesting an escape hatch).
      I also took advantage of having to reformat pg_operator to fix something
      that'd been bugging me for a while: mergejoinable operators should have
      explicit links to the associated cross-data-type comparison operators,
      rather than hardwiring an assumption that they are named < and >.
      6cef5d25
  27. 11 Apr, 2002 1 commit
    • Tom Lane's avatar
      Restructure representation of aggregate functions so that they have pg_proc · 902a6a0a
      Tom Lane authored
      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
  28. 09 Apr, 2002 1 commit
  29. 29 Mar, 2002 1 commit
  30. 26 Mar, 2002 1 commit
  31. 21 Mar, 2002 1 commit
  32. 02 Nov, 2001 1 commit
    • Tom Lane's avatar
      Fix problem reported by Alex Korn: if a relation has been dropped and · 7d053108
      Tom Lane authored
      recreated since the start of our transaction, our first reference to it
      errored out because we'd try to reuse our old relcache entry for it.
      Do this by accepting SI inval messages just before relcache search in
      heap_openr, so that dead relcache entries will be flushed before we
      search.  Also, break heap_open/openr into two pairs of routines,
      relation_open(r) and heap_open(r).  The relation_open routines make
      no tests on relkind and so can be used to open anything that has a
      pg_class entry.  The heap_open routines are wrappers that add a relkind
      test to preserve their established behavior.  Use the relation_open
      routines in several places that had various kluge solutions for opening
      rels that might be either heap or index rels.
      
      Also, remove the old 'heap stats' code that's been superseded by Jan's
      stats collector, and clean up some inconsistencies in error reporting
      between the different types of ALTER TABLE.
      7d053108
  33. 25 Oct, 2001 1 commit
  34. 03 Oct, 2001 1 commit
  35. 10 Aug, 2001 1 commit
    • Tom Lane's avatar
      Make OIDs optional, per discussions in pghackers. WITH OIDS is still the · bf56f075
      Tom Lane authored
      default, but OIDS are removed from many system catalogs that don't need them.
      Some interesting side effects: TOAST pointers are 20 bytes not 32 now;
      pg_description has a three-column key instead of one.
      
      Bugs fixed in passing: BINARY cursors work again; pg_class.relhaspkey
      has some usefulness; pg_dump dumps comments on indexes, rules, and
      triggers in a valid order.
      
      initdb forced.
      bf56f075
  36. 25 Jun, 2001 1 commit
    • Tom Lane's avatar
      Optimizer can now estimate selectivity of IS NULL, IS NOT NULL, · 4d58a7ca
      Tom Lane authored
      IS TRUE, etc, with some degree of verisimilitude.  Split out
      selectivity support functions from builtins.h into a new header
      file selfuncs.h, so as to reduce the number of header files builtins.h
      must depend on.  Fix a few missing inclusions exposed thereby.
      From Joe Conway, with some kibitzing from Tom Lane.
      4d58a7ca
  37. 13 Jun, 2001 1 commit
    • Tom Lane's avatar
      Allow a non-superuser database owner to vacuum all tables in his · 1a6bb6d8
      Tom Lane authored
      database, including system catalogs (but not the shared catalogs,
      since they don't really belong to his database).  This is per recent
      mailing list discussion.  Clean up some other code that also checks
      for database ownerness by introducing a test function is_dbadmin().
      1a6bb6d8
  38. 05 Jun, 2001 1 commit
  39. 27 May, 2001 1 commit
  40. 22 Mar, 2001 1 commit