Received: from localhost (maia-1.hub.org [200.46.204.191]) by postgresql.org (Postfix) with ESMTP id C3A1B9FB815 for ; Tue, 5 Jun 2007 17:51:24 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.191]) (amavisd-maia, port 10024) with ESMTP id 73480-06 for ; Tue, 5 Jun 2007 17:51:20 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.4 Received: from svr4.postgresql.org (svr4.postgresql.org [66.98.251.159]) by postgresql.org (Postfix) with ESMTP id 304849FBCA9 for ; Tue, 5 Jun 2007 17:51:20 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.3 Received: from BRUBLUmx12.mactelecom.net (BRUBLUmx12.mactelecom.net [217.64.240.4]) by svr4.postgresql.org (Postfix) with ESMTP id A953E5AF03F for ; Tue, 5 Jun 2007 20:51:19 +0000 (GMT) Received: from smtp.eurofer.be (217.64.254.218.mactelecom.net [217.64.254.218]) by BRUBLUmx12.mactelecom.net (Postfix) with ESMTP id CF16F838040; Tue, 5 Jun 2007 22:51:14 +0200 (CEST) Received: from ip-80-236-228-116.dsl.scarlet.be ([80.236.228.116] helo=[192.168.1.101]) by smtp.eurofer.be with esmtpsa (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.63) (envelope-from ) id 1HvfzT-0000wT-D0; Tue, 05 Jun 2007 22:51:14 +0200 Message-ID: <4665CCAB.4000704@eurofer.be> Date: Tue, 05 Jun 2007 22:50:51 +0200 From: De Leeuw Guy User-Agent: IceDove 1.5.0.10 (X11/20070329) MIME-Version: 1.0 To: Kristo Kaiv Cc: pgsql-admin@postgresql.org References: <46647A79.3020401@eurofer.be> In-Reply-To: X-Enigmail-Version: 0.94.2.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Spam_score: -3.5 X-SA-Exim-Connect-IP: 80.236.228.116 X-SA-Exim-Mail-From: G.De_Leeuw@eurofer.be Subject: Re: get the array content whis the select clause X-SA-Exim-Scanned: Yes (on smtp.eurofer.be) X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.043 tagged_above=0 required=5 tests=AWL=0.093, BAYES_40=-0.185, FORGED_RCVD_HELO=0.135 X-Spam-Level: X-Archive-Number: 200706/34 X-Sequence-Number: 25702 Great !!! Many thanks Kristo, it's just what I need Guy Kristo Kaiv a écrit : > i guess this what you meant: > (not a nice solution though) writing a function that returns the set > would be a better idea > > create table testintarr (iarr int[]); > insert into testintarr values ('5,6,7,8'); > > test=# select iarr[idx] from (select iarr, > generate_series(array_lower(iarr,1), array_upper(iarr,1)) as idx from > testintarr) asdf; > iarr > ------ > 5 > 6 > 7 > 8 > (4 rows) > > BR, > Kristo > > On 04.06.2007, at 23:47, De Leeuw Guy wrote: > >> Hello all >> >> It is possible to return the content of an int array [] with a select >> clause ? >> >> Thanks in advance for your respons >> >> Guy >> >> ---------------------------(end of broadcast)--------------------------- >> TIP 1: if posting/reading through Usenet, please send an appropriate >> subscribe-nomail command to majordomo@postgresql.org so that your >> message can get through to the mailing list cleanly > > > ---------------------------(end of broadcast)--------------------------- > TIP 3: Have you checked our extensive FAQ? > > http://www.postgresql.org/docs/faq