Received: from localhost (maia-2.hub.org [200.46.204.187]) by postgresql.org (Postfix) with ESMTP id 109639FBC2F for ; Thu, 3 May 2007 04:17:28 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.187]) (amavisd-maia, port 10024) with ESMTP id 49147-08 for ; Thu, 3 May 2007 04:17:22 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.5 Received: from an-out-0708.google.com (an-out-0708.google.com [209.85.132.243]) by postgresql.org (Postfix) with ESMTP id 8E76D9FBC2E for ; Thu, 3 May 2007 04:17:24 -0300 (ADT) Received: by an-out-0708.google.com with SMTP id c24so424429ana for ; Thu, 03 May 2007 00:17:21 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=eDsMQmZqtYLZx9rDajFoFYAL+DuyIKHbhOCQX0797z5K/Zgm8szC6PN9HKlaEYvy30Lm9afI3d7j+7iOPsPd5lHGxylNr/RiIrGOX2C0jxZgIt2dd7lGGawf5vUQDvtLbdxz0Wd5z9F3fwpLILkletV+M2WCUZQeIabIiUim34c= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=UM3Thyd8Vw4M5ZwNnUXLE4tnyhLM2H9kZPXqJZ9bC0EoHTikL3R9tS2SOMpy8aCrB9zz/N+sNSTM15bcsvlewu4xmqOkNQAGi2T9vV568oPbNkSl7pFAELTFx+4gXwyaBw0RTAFqSw3y0wvn3DfRBoCuNbPQi9Dahrxr4v3UpjE= Received: by 10.100.171.16 with SMTP id t16mr1294130ane.1178176641855; Thu, 03 May 2007 00:17:21 -0700 (PDT) Received: by 10.100.154.9 with HTTP; Thu, 3 May 2007 00:17:21 -0700 (PDT) Message-ID: Date: Thu, 3 May 2007 02:17:21 -0500 From: "=?ISO-8859-1?Q?Rodrigo_De_Le=F3n?=" To: pgsql-sql@postgresql.org Subject: Re: Needs Function In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=WINDOWS-1252; format=flowed Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200705/14 X-Sequence-Number: 28295 On 5/2/07, Penchalaiah P. wrote: > I need a user defined function for the following purpose=85. > > If I pass a string with comma ( , ) separated chars/values=85. It should = be appear in next line=85 > > Ex: select get_sep_str ('SK, rp, h, j, 6, 9, kl') from dual; > > Output : > > SK > > rp > > h > > j > > 6 > > 9 > > kl > > > > (Or) > > > > I have one table like this=85.. > > > > Temp Table: > > > > Deptno number(10) > > Empno varchar2(200); > > > > Data in temp table: > > > > Deptno Empno > > ----------- ------------ > > 10 B3091,B3092,B3093,B3085 > > 11 3651,6521 > > 12 H3062 > > > > Now, I want to display the data like this=85.. > > > > Deptno Empno > > --------- --------- > > 10 B3091 > > 10 B3092 > > 10 B3093 > > 10 B3094 > > 11 3651 > > 11 6521 > > 12 H3062 > > Now, how can I achieve this=85. See: http://archives.postgresql.org/pgsql-general/2005-12/msg00080.php