Re: spring a string to rows (Postgresql 8.4)

From: Raymond O'Donnell <rod(at)iol(dot)ie>
To: emilu(at)encs(dot)concordia(dot)ca
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: spring a string to rows (Postgresql 8.4)
Date: 2013-01-07 19:52:49
Message-ID: 50EB2791.1010309@iol.ie
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 07/01/2013 19:44, Emi Lu wrote:
> Hello,
>
> Is there a function to split a string to different rows?
>
> For example, t1(id, col1)
> values(1, 'a, b, c');

regexp_split_to_table() should do it:

http://www.postgresql.org/docs/8.4/static/functions-string.html

HTH

Ray.

--
Raymond O'Donnell :: Galway :: Ireland
rod(at)iol(dot)ie

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Thomas Kellerer 2013-01-07 19:54:31 Re: spring a string to rows (Postgresql 8.4)
Previous Message Emi Lu 2013-01-07 19:44:01 spring a string to rows (Postgresql 8.4)