Skip to content
Snippets Groups Projects
  1. Nov 15, 2007
  2. Sep 22, 2007
  3. Sep 18, 2007
    • Andrew Dunstan's avatar
      Close previously open holes for invalidly encoded data to enter the · 55613bf9
      Andrew Dunstan authored
      database via builtin functions, as recently discussed on -hackers.
      
      chr() now returns a character in the database encoding. For UTF8 encoded databases
      the argument is treated as a Unicode code point. For other multi-byte encodings
      the argument must designate a strict ascii character, or an error is raised,
      as is also the case if the argument is 0.
      
      ascii() is adjusted so that it remains the inverse of chr().
      
      The two argument form of convert() is gone, and the three argument form now
      takes a bytea first argument and returns a bytea. To cover this loss three new
      functions are introduced:
      . convert_from(bytea, name) returns text - converts the first argument from the
        named encoding to the database encoding
      . convert_to(text, name) returns bytea - converts the first argument from the
        database encoding to the named encoding
      . length(bytea, name) returns int - gives the length of the first argument in
        characters in the named encoding
      55613bf9
  4. Feb 28, 2007
    • Tom Lane's avatar
      Replace direct assignments to VARATT_SIZEP(x) with SET_VARSIZE(x, len). · 234a02b2
      Tom Lane authored
      Get rid of VARATT_SIZE and VARATT_DATA, which were simply redundant with
      VARSIZE and VARDATA, and as a consequence almost no code was using the
      longer names.  Rename the length fields of struct varlena and various
      derived structures to catch anyplace that was accessing them directly;
      and clean up various places so caught.  In itself this patch doesn't
      change any behavior at all, but it is necessary infrastructure if we hope
      to play any games with the representation of varlena headers.
      Greg Stark and Tom Lane
      234a02b2
  5. Feb 08, 2007
  6. Jan 05, 2007
  7. Jul 14, 2006
  8. Mar 05, 2006
  9. Nov 04, 2005
  10. Oct 29, 2005
  11. Oct 15, 2005
  12. Aug 24, 2005
  13. May 07, 2005
  14. Mar 16, 2005
  15. Dec 31, 2004
    • PostgreSQL Daemon's avatar
      · 2ff50159
      PostgreSQL Daemon authored
      Tag appropriate files for rc3
      
      Also performed an initial run through of upgrading our Copyright date to
      extend to 2005 ... first run here was very simple ... change everything
      where: grep 1996-2004 && the word 'Copyright' ... scanned through the
      generated list with 'less' first, and after, to make sure that I only
      picked up the right entries ...
      2ff50159
  16. Oct 19, 2004
  17. Aug 29, 2004
  18. Jun 07, 2004
  19. May 26, 2004
  20. May 22, 2004
    • Tom Lane's avatar
      Use wide-character library routines, if available, for upper/lower/initcap · 39838694
      Tom Lane authored
      functions.  This allows these functions to work correctly with Unicode and
      other multibyte encodings.  Per prior discussion.
      
      Also, revert my earlier change to move installation path mashing from
      Makefile.global to configure.  Turns out not to work well because configure
      script is working with unexpanded variables, and so fails to match in
      cases where it should match.
      39838694
  21. Feb 27, 2004
  22. Nov 29, 2003
    • PostgreSQL Daemon's avatar
      · 969685ad
      PostgreSQL Daemon authored
      $Header: -> $PostgreSQL Changes ...
      969685ad
  23. Aug 08, 2003
  24. Aug 04, 2003
  25. Jul 27, 2003
  26. May 24, 2003
    • Tom Lane's avatar
      Improve implementation of btrim/ltrim/rtrim: provide a special case for · 11d5c820
      Tom Lane authored
      single-byte encodings, and a direct C implementation of the single-argument
      forms (where spaces are always what gets trimmed).  This is in preparation
      for using rtrim1() as the bpchar-to-text cast operator, but is a useful
      performance improvement even if we decide not to do that.
      11d5c820
  27. Sep 04, 2002
  28. Aug 29, 2002
  29. Aug 22, 2002
    • Bruce Momjian's avatar
      b4f24fed
    • Bruce Momjian's avatar
      This patch should fix the problem. Doesn't include my previous patch · d86dee3e
      Bruce Momjian authored
      for repeat(). Again, somewhat off-the-cuff, so I might have missed
      something...
      
      test=# select lpad('xxxxx',1431655765,'yyyyyyyyyyyyyyyy');
      ERROR:  Requested length too large
      test=# select rpad('xxxxx',1431655765,'yyyyyyyyyyyyyyyy');
      ERROR:  Requested length too large
      
      (That's on a Unicode DB, haven't tested other encodings but AFAICT
      this fix should still work.)
      
      Neil Conway
      d86dee3e
    • Bruce Momjian's avatar
      repeat() fix: · cbe733d7
      Bruce Momjian authored
      > Neil Conway <neilc@samurai.com> writes:
      > > +   /* Check for integer overflow */
      > > +   if (tlen / slen != count)
      > > +           elog(ERROR, "Requested buffer is too large.");
      >
      > What about slen == 0?
      
      Good point -- that wouldn't cause incorrect results or a security
      problem, but it would reject input that we should really accept.
      
      Revised patch is attached.
      
      Neil Conway
      cbe733d7
  30. Jun 20, 2002
  31. Jan 08, 2002
  32. Oct 25, 2001
  33. Sep 23, 2001
Loading