URL Decoding

From: Arnaud Lesauvage <thewild(at)freesurf(dot)fr>
To: pgsql-general(at)postgresql(dot)org
Subject: URL Decoding
Date: 2006-11-22 13:36:53
Message-ID: 45645275.5020900@freesurf.fr
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi List !

I am looking for an easy URL decoding function.
I thought about using regexp_replace, but I cna't get it to
work :

SELECT regexp_replace('foo%B5bar', '%(..)', '\x\\1' , 'g');
> 'fooxB5bar'

I wanted to replace %BE with the character \xB5 (µ, I
think), but of course I am doing this wrong...
Is there a simple way t odo this ?

Thanks a lot !

--
Arnaud

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Alvaro Herrera 2006-11-22 13:43:18 Re: MSSQL to PostgreSQL : Encoding problem
Previous Message Ray Stell 2006-11-22 12:57:57 Re: list archives