Re: Passing a comma delimited list to a function

From: "Ezra Epstein" <news-reader(at)prajnait(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: Passing a comma delimited list to a function
Date: 2004-01-07 05:00:10
Message-ID: 4uOdnUwZt7z2D2aiXTWc-g@speakeasy.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Take a look at:
http://www.postgres.org/docs/current/static/functions-string.html

The split_part() function should do the trick.

== Ezra Epstein

"A E" <cooljoint(at)yahoo(dot)com> wrote in message
news:20040103181155(dot)67492(dot)qmail(at)web12103(dot)mail(dot)yahoo(dot)com(dot)(dot)(dot)
Hi,

I was wondering if there was a function that handles list elements of a
comma delimited list? I need to be able to pass values as a comma delimited
list, count the number of values, and process the value of each.

Did not think it was very efficient to loop through the contents of the list
finding delimiters.

TIA
Alex

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Ezra Epstein 2004-01-07 05:04:01 Re: Any way to have CREATEUSER privs without having all privs?
Previous Message Ezra Epstein 2004-01-07 04:53:43 Re: Anything akin to an Evaluate Statement in Postgresql?