function - Mailing list pgsql-sql

From Normunds
Subject function
Date
Msg-id 078001c0129a$a2354ec0$1708050a@mt.lv
Whole thread Raw
Responses Re: [GENERAL] function  (Jan Wieck <janwieck@Yahoo.com>)
Re: [GENERAL] function  (Ian Turner <vectro@pipeline.com>)
List pgsql-sql
Hi all,

how can I write function which takes text from one field, replaces
some characters and puts it in other field? I have array with old and
new values.

For example:
old array = {'r', 'Z', 'o'}
new array = {'s', 'm', 't'}
old field value = 'Zorro'
new field value which must calculate this function = 'mtsst'

This function will be used in update trigger.
Any ideas?

Normunds


pgsql-sql by date:

Previous
From: "Ryan Williams"
Date:
Subject: Re: Viewing a function
Next
From: Jie Liang
Date:
Subject: Re: Optimizing huge inserts/copy's