Andrew Dunstan wrote:
> 
> 
> Bruce Momjian wrote:
> > Magnus Hagander wrote:
> >   
> >> On Thu, Sep 3, 2009 at 13:31, Andrew Dunstan<and...@dunslane.net> wrote:
> >>     
> >>> Magnus Hagander wrote:
> >>>       
> >>>> Oh, hang on, "the NULL string" refers to the copy parameter? Not a
> >>>> part of the data? I read it as "a string being NULL". Maybe something
> >>>> like "the value of the NULL string parameter" to be overly clear for
> >>>> people like me? :-)
> >>>>
> >>>>         
> >>> We could change:
> >>>
> >>> ? A NULL is output as the NULL string and is not quoted, while a data 
> >>> value
> >>> ? matching the NULL string is quoted.
> >>>
> >>>
> >>> to
> >>>
> >>> ? A NULL is output as the NULL parameter and is not quoted, while a 
> >>> non-NULL
> >>> data value whose text representation
> >>> ? matches the NULL parameter is quoted.
> >>>
> >>>
> >>> or something similar. Would that be better?
> >>>       
> >> Yes, much better IMO.
> >>     
> >
> > I have applied the attached documentation clarification patch, and
> > backpatched it to 8.4.X.
> >
> >   
> >   
> 
> Why didn't you follow the wording I actually suggested, which had the 
> virtue of being accurate.

I thought the problem was the use of the word "null string", which
clearly was confusing.  

I have updated the docs to use your wording, with a little
clarification.  The diff against yesterday's CVS is attached, which is
not smaller.

-- 
  Bruce Momjian  <br...@momjian.us>        http://momjian.us
  EnterpriseDB                             http://enterprisedb.com

  + If your life is a hard drive, Christ can be your backup. +
Index: copy.sgml
===================================================================
RCS file: /cvsroot/pgsql/doc/src/sgml/ref/copy.sgml,v
retrieving revision 1.87
diff -c -r1.87 copy.sgml
*** copy.sgml	5 Sep 2009 23:58:01 -0000	1.87
--- copy.sgml	17 Sep 2009 21:47:11 -0000
***************
*** 1,5 ****
  <!--
! $PostgreSQL: pgsql/doc/src/sgml/ref/copy.sgml,v 1.87 2009/09/05 23:58:01 tgl Exp $
  PostgreSQL documentation
  -->
  
--- 1,5 ----
  <!--
! $PostgreSQL: pgsql/doc/src/sgml/ref/copy.sgml,v 1.88 2009/09/17 21:13:01 momjian Exp $
  PostgreSQL documentation
  -->
  
***************
*** 552,561 ****
      <literal>NULL</> value from an empty string.
      <productname>PostgreSQL</>'s <command>COPY</> handles this by
      quoting. A <literal>NULL</> is output as the <literal>NULL</>
!     string and is not quoted, while a data value matching the
!     <literal>NULL</> string is quoted. Therefore, using the default
      settings, a <literal>NULL</> is written as an unquoted empty
!     string, while an empty string is written with double quotes
      (<literal>""</>). Reading values follows similar rules. You can
      use <literal>FORCE NOT NULL</> to prevent <literal>NULL</> input
      comparisons for specific columns.
--- 552,561 ----
      <literal>NULL</> value from an empty string.
      <productname>PostgreSQL</>'s <command>COPY</> handles this by
      quoting. A <literal>NULL</> is output as the <literal>NULL</>
!     parameter and is not quoted, while a non-NULL value matching the
!     the <literal>NULL</> parameter string is quoted. Therefore, using the default
      settings, a <literal>NULL</> is written as an unquoted empty
!     string, while an empty string data value is written with double quotes
      (<literal>""</>). Reading values follows similar rules. You can
      use <literal>FORCE NOT NULL</> to prevent <literal>NULL</> input
      comparisons for specific columns.
-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to