On Wed, Dec 22, 2004 at 07:50:56AM -0800, srini vasan wrote:
Hi,
> Can anybody please help me in this?
You could use the replace(text,text,text) function:
alvherre=# create table foo (a text);
CREATE TABLE
alvherre=# insert into foo values ('hola
alvherre'# ');
INSERT 155224 1
alvherre=# select * from foo;
a
-------
hola
(1 fila)
alvherre=# select replace(a, '\n', '\\n') from foo;
replace
---------
hola\n
(1 fila)
--
Alvaro Herrera (<alvherre[(at)]dcc(dot)uchile(dot)cl>)
"Para tener más hay que desear menos"