| From: | gherzig(at)fmed(dot)uba(dot)ar |
|---|---|
| To: | "Jasen Betts" <jasen(at)xnet(dot)co(dot)nz> |
| Cc: | pgsql-sql(at)postgresql(dot)org |
| Subject: | Re: problem using regexp_replace |
| Date: | 2010-01-11 10:33:33 |
| Message-ID: | 4b9e9f07701f20f59fa63e18f73cb311.squirrel@www.webmail.fmed.uba.ar |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-sql |
> On 2010-01-11, gherzig(at)fmed(dot)uba(dot)ar <gherzig(at)fmed(dot)uba(dot)ar> wrote:
>
>> CREATE FUNCTION valores_sustitucion(valor_ingresado varchar[])
>> returns varchar
>> as
>> $$
>> select case
>> $1[1] when 'Action_1' then
>> (select descripcion from load_by_cod($1[2]))
>>
>> when 'Action_2' then (select descripcion from pay_by_view($1[2])
>>
>> else 'FALSE'
>> end;
>> $$ language sql;
>
>> Anybody has a hint?
>
> you are missing a )
>
Oh, thats a copy-paste problem, sory about that.
I forgot to mention, this is a 8.3 running on linux.
Gerardo
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Andy Shellam | 2010-01-11 19:49:50 | CHECK constraint removing brackets |
| Previous Message | Jasen Betts | 2010-01-11 08:28:36 | Re: problem using regexp_replace |