X-Original-To: pgsql-performance-postgresql.org@postgresql.org Received: from localhost (mx1.hub.org [200.46.208.251]) by postgresql.org (Postfix) with ESMTP id 2E1C29FA31F for ; Thu, 29 Jun 2006 14:00:52 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.208.251]) (amavisd-new, port 10024) with ESMTP id 20461-04 for ; Thu, 29 Jun 2006 14:00:43 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey- Received: from floppy.pyrenet.fr (news.pyrenet.fr [194.116.145.2]) by postgresql.org (Postfix) with ESMTP id 0AD069FA081 for ; Thu, 29 Jun 2006 14:00:42 -0300 (ADT) Received: by floppy.pyrenet.fr (Postfix, from userid 106) id 6B36F30920; Thu, 29 Jun 2006 19:00:41 +0200 (MET DST) From: satishchandra999@gmail.com X-Newsgroups: pgsql.performance Subject: Calling a SP from Curosor loop Date: 29 Jun 2006 10:00:35 -0700 Organization: http://groups.google.com Lines: 38 Message-ID: <1151600435.709010.253120@j72g2000cwa.googlegroups.com> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" X-Complaints-To: groups-abuse@google.com User-Agent: G2/0.2 X-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 1.1.4322; .NET CLR 2.0.50727),gzip(gfe),gzip(gfe) Complaints-To: groups-abuse@google.com Injection-Info: j72g2000cwa.googlegroups.com; posting-host=68.114.93.188; posting-account=armG6w0AAADy3k9hQbRs0Nrb4eOCYes4 To: pgsql-performance@postgresql.org X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200607/5 X-Sequence-Number: 19865 I have SP, which has a cursor iterations. Need to call another SP for every loop iteration of the cursor. The pseudo code is as follows.. Create proc1 as Begin Variable declrations... declare EffectiveDate_Cursor cursor for select field1,fld2 from tab1,tab2 where tab1.effectivedate