Received: from localhost (maia-2.hub.org [200.46.204.187]) by postgresql.org (Postfix) with ESMTP id ECE959FB610 for ; Thu, 14 Jun 2007 03:05:13 -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 80991-06 for ; Thu, 14 Jun 2007 03:05:01 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.4 Received: from nz-out-0506.google.com (nz-out-0506.google.com [64.233.162.228]) by postgresql.org (Postfix) with ESMTP id 3C1C09FB618 for ; Thu, 14 Jun 2007 03:05:08 -0300 (ADT) Received: by nz-out-0506.google.com with SMTP id m22so392784nzf for ; Wed, 13 Jun 2007 23:05:07 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:from:to:cc:references:in-reply-to:subject:date:message-id:mime-version:content-type:content-transfer-encoding:x-mailer:thread-index:content-language; b=AcJ0WwBgTJ7zawe99MmNNJWrXDQZE6IMw45pac2lB1JxfGFT/IXEqjZs4S1WLMMZL++t/9VQtgTlyYReZaLpU4wcI0sDYhFvK4GqsAjj1J4KiFAnIn5IR/ly2tQqo22LIQDW9EY9jWLsamV2SAxxN0SzhYelWQGFkKhCt1xUwi0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:from:to:cc:references:in-reply-to:subject:date:message-id:mime-version:content-type:content-transfer-encoding:x-mailer:thread-index:content-language; b=TfH99yZF/KjfBsCUDuksOST5t9Ku1UmMZaezLwo2A+X5Udee9G9xdn8Lh6SLpST0x3Fu6BGiEyOetd37UsIinWGpF6P2n62BQ1vJGIVS39aEunPFEleDYT6S1x5DugThGNiCqRc+pX8MFsnyp7lvx6X2O337WGPnWnnX3ogSurQ= Received: by 10.114.130.1 with SMTP id c1mr1496326wad.1181801107066; Wed, 13 Jun 2007 23:05:07 -0700 (PDT) Received: from bitdldt04 ( [122.162.156.12]) by mx.google.com with ESMTP id l22sm3414263waf.2007.06.13.23.05.04 (version=SSLv3 cipher=RC4-MD5); Wed, 13 Jun 2007 23:05:06 -0700 (PDT) From: "Jyoti Seth" To: "'Pavel Stehule'" Cc: , References: <000001c7adb1$fb497360$f1dc5a20$@com> <162867790706130555r5a1ba9cbq1c3e2cb0f1adbda7@mail.gmail.com> <003201c7ae47$7ff80460$7fe80d20$@com> <162867790706132257v53da9fb7raebee4f4ed50e00e@mail.gmail.com> In-Reply-To: <162867790706132257v53da9fb7raebee4f4ed50e00e@mail.gmail.com> Subject: Re: [SQL] setof or array as input parameter to postgresql 8.2 functions Date: Thu, 14 Jun 2007 11:34:03 +0530 Message-ID: <003401c7ae49$d21007a0$763016e0$@com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 12.0 Thread-Index: AceuSNeEHCVvf67fQym2g7rqaNtHVgAAGvoQ Content-Language: en-us X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200706/827 X-Sequence-Number: 115650 Thanks a lot. Regards, Jyoti -----Original Message----- From: Pavel Stehule [mailto:pavel.stehule@gmail.com] Sent: Thursday, June 14, 2007 11:27 AM To: Jyoti Seth Cc: pgsql-general@postgresql.org; pgsql-sql@postgresql.org Subject: Re: [SQL] setof or array as input parameter to postgresql 8.2 functions 2007/6/14, Jyoti Seth : > Thanks for the solution. With this I am able to pass arrays and > multidimensional arrays in postgresql functions. > > One of my problem is still left I want to pass set of values with different > datatypes.For eg: > I want to pass following values to the function: > 1 ajay 1000.12 > 2 rita 2300.24 > 3 leena 1230.78 > 4 jaya 3432.45 > > As the values have different data types I have to create three different > arrays. Is there any way with which I can pass this as a single setof > values. > > You have to wait for 8.3 where arrays on composite types are supported. Currently in one our application we use array of arrays where different types are too, and we cast it to text. Regards Pavel