pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Jonas Forsman <jfo123@hotmail.com>
To: pgsql-bugs@postgresql.org
Subject: BUG #6295: Update fails on empty concatenated strings
Date: Wed, 16 Nov 2011 08:47:12 GMT
Message-ID: <201111160847.pAG8lCdx067272@wwwmaster.postgresql.org> (raw)


The following bug has been logged online:

Bug reference:      6295
Logged by:          Jonas Forsman
Email address:      jfo123@hotmail.com
PostgreSQL version: 8.4.9
Operating system:   Ubuntu 10.04 LTS
Description:        Update fails on empty concatenated strings
Details: 

Field description (note the field name is "comment") :
comment character varying(2048)

sql:
UPDATE user SET comment= E'[2011-11-16] Note to myself no: 171\\n' ||
comment WHERE userid=1

This query fails if comment is an empty string or null.

This works:

UPDATE user SET comment= E'[2011-11-16] Note to myself no: 171\\n' ||
comment || '' WHERE userid=1



view thread (3+ messages)  latest in thread

Message-ID: <201111160847.pAG8lCdx067272@wwwmaster.postgresql.org>
Permalink:  ../201111160847.pAG8lCdx067272@wwwmaster.postgresql.org/
Also on:    postgresql.org/message-id/201111160847.pAG8lCdx067272@wwwmaster.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-bugs@postgresql.org
  Cc: jfo123@hotmail.com
  Subject: Re: BUG #6295: Update fails on empty concatenated strings
  In-Reply-To: <201111160847.pAG8lCdx067272@wwwmaster.postgresql.org>
  References: <201111160847.pAG8lCdx067272@wwwmaster.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox