Re: Insert a space between each character - Mailing list pgsql-sql

From A. Kretschmer
Subject Re: Insert a space between each character
Date
Msg-id 20080917063947.GA22919@a-kretschmer.de
Whole thread Raw
In response to Insert a space between each character  ("Nicholas I" <nicholas.domnic.i@gmail.com>)
List pgsql-sql
am  Wed, dem 17.09.2008, um 11:49:27 +0530 mailte Nicholas I folgendes:
> Hi,
> 
>  can anybody help me, to insert a space between each character in postgresql.
> 
>  for example,
> 
>   ABC
> 
>  output
>   A B C

write a function in plpgsql, you can use string-function like substr to
split the string. Write a loop over the string, pick up every char, and
concatenate a space. Return the new string.


Andreas
-- 
Andreas Kretschmer
Kontakt:  Heynitz: 035242/47150,   D1: 0160/7141639 (mehr: -> Header)
GnuPG-ID:   0x3FFF606C, privat 0x7F4584DA   http://wwwkeys.de.pgp.net


pgsql-sql by date:

Previous
From: "Nicholas I"
Date:
Subject: Insert a space between each character
Next
From: Michael Toews
Date:
Subject: Re: Insert a space between each character