Re: regexp_replace failing on 9.0.4

From: Rob Sargentg <robjsargent(at)gmail(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: regexp_replace failing on 9.0.4
Date: 2013-03-19 04:04:00
Message-ID: 5147E3B0.5030207@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


> Maybe we're barking up the wrong tree by suspecting the regex itself.
> Perhaps the updates were suppressed by a trigger, or the transaction
> rolled back instead of committing, or some such?
>
> regards, tom lane
Barking mad, more like it. I had rolled back the execution of my
function in my dev env. and running again produces the same result as
experienced in production system.

Why the update of the text type field view regexp_replace is failing
still confuses me, but that's pretty much my natural state. The size of
the text field ranges from 7.5k to 24k char.

Here is the update (again)
update cms.segment_data s
set text = regexp_replace(f.content,
'(^.*)ns/acres/pathology/dx/1.5(.*$)', E'\\1ns/acres/pathology/dx/1.6\\2')
from
dm.payload_segment p,
support.fix_pathdx_namespace f
where s.id = p.segment_data_id
and p.item_id = f.item_id
and p.content_version = f.maxversion
;

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Craig Ringer 2013-03-19 05:28:10 Re: [HACKERS] Trust intermediate CA for client certificates
Previous Message Ray Stell 2013-03-19 02:45:42 Re: .backup file documentation