1. 31 7月, 2008 2 次提交
    • T
      Adjust citext to make use of the new ability to declare its type category: · 42be2c79
      Tom Lane 提交于
      by putting it into the standard string category, we cause casts from citext
      to text to be recognized as "preferred" casts.  This eliminates the need
      for creation of alias functions and operators that only serve to prevent
      ambiguous-function errors; get rid of the ones that were in the original
      commit.
      42be2c79
    • T
      Replace the hard-wired type knowledge in TypeCategory() and IsPreferredType() · bac3e836
      Tom Lane 提交于
      with system catalog lookups, as was foreseen to be necessary almost since
      their creation.  Instead put the information into two new pg_type columns,
      typcategory and typispreferred.  Add support for setting these when
      creating a user-defined base type.
      
      The category column is just a "char" (i.e. a poor man's enum), allowing
      a crude form of user extensibility of the category list: just use an
      otherwise-unused character.  This seems sufficient for foreseen uses,
      but we could upgrade to having an actual category catalog someday, if
      there proves to be a huge demand for custom type categories.
      
      In this patch I have attempted to hew exactly to the behavior of the
      previous hardwired logic, except for introducing new type categories for
      arrays, composites, and enums.  In particular the default preferred state
      for user-defined types remains TRUE.  That seems worth revisiting, but it
      should be done as a separate patch from introducing the infrastructure.
      Likewise, any adjustment of the standard set of categories should be done
      separately.
      bac3e836
  2. 30 7月, 2008 1 次提交
  3. 29 7月, 2008 2 次提交
  4. 27 7月, 2008 1 次提交
    • T
      As noted by Andrew Gierth, there's really no need any more to force a junk · a77eaa6a
      Tom Lane 提交于
      filter to be used when INSERT or SELECT INTO has a plan that returns raw
      disk tuples.  The virtual-tuple-slot optimizations that were put in place
      awhile ago mean that ExecInsert has to do ExecMaterializeSlot, and that
      already copies the tuple if it's raw (and does so more efficiently than
      a junk filter, too).  So get rid of that logic.  This in turn means that
      we can throw away ExecMayReturnRawTuples, which wasn't used for any other
      purpose, and was always a kluge anyway.
      
      In passing, move a couple of SELECT-INTO-specific fields out of EState
      and into the private state of the SELECT INTO DestReceiver, as was foreseen
      in an old comment there.  Also make intorel_receive use ExecMaterializeSlot
      not ExecCopySlotTuple, for consistency with ExecInsert and to possibly save
      a tuple copy step in some cases.
      a77eaa6a
  5. 25 7月, 2008 2 次提交
  6. 24 7月, 2008 3 次提交
  7. 23 7月, 2008 1 次提交
  8. 21 7月, 2008 4 次提交
  9. 20 7月, 2008 1 次提交
  10. 19 7月, 2008 5 次提交
    • T
      Avoid substituting NAMEDATALEN, FLOAT4PASSBYVAL, and FLOAT8PASSBYVAL into · 4b362c66
      Tom Lane 提交于
      the postgres.bki file during build, because we want that file to be entirely
      platform- and configuration-independent; else it can't safely be put into
      /usr/share on multiarch machines.  We can do the substitution during initdb,
      instead.  FLOAT4PASSBYVAL and FLOAT8PASSBYVAL are new breakage as of 8.4,
      while the NAMEDATALEN hazard has been there all along but I guess no one
      tripped over it.  Noticed while trying to build "universal" OS X binaries.
      4b362c66
    • T
      Adjust things so that the query_string of a cached plan and the sourceText of · a1c69235
      Tom Lane 提交于
      a portal are never NULL, but reliably provide the source text of the query.
      It turns out that there was only one place that was really taking a short-cut,
      which was the 'EXECUTE' utility statement.  That doesn't seem like a
      sufficiently critical performance hotspot to justify not offering a guarantee
      of validity of the portal source text.  Fix it to copy the source text over
      from the cached plan.  Add Asserts in the places that set up cached plans and
      portals to reject null source strings, and simplify a bunch of places that
      formerly needed to guard against nulls.
      
      There may be a few places that cons up statements for execution without
      having any source text at all; I found one such in ConvertTriggerToFK().
      It seems sufficient to inject a phony source string in such a case,
      for instance
              ProcessUtility((Node *) atstmt,
                             "(generated ALTER TABLE ADD FOREIGN KEY command)",
                             NULL, false, None_Receiver, NULL);
      
      We should take a second look at the usage of debug_query_string,
      particularly the recently added current_query() SQL function.
      
      ITAGAKI Takahiro and Tom Lane
      a1c69235
    • T
      Provide a function hook to let plug-ins get control around ExecutorRun. · 6cc88f0a
      Tom Lane 提交于
      ITAGAKI Takahiro
      6cc88f0a
    • B
      Properly document archive/restore command examples on Windows. · 8d7af890
      Bruce Momjian 提交于
      ITAGAKI Takahiro
      8d7af890
    • B
      25c9de4d
  11. 18 7月, 2008 7 次提交
  12. 17 7月, 2008 5 次提交
  13. 16 7月, 2008 6 次提交