From: Connor McDonald Subject: Re: return cursor from a function and use it in an other statment Date: 2000/07/07 Message-ID: <3965ABC9.59C3@yahoo.com>#1/1 Content-Transfer-Encoding: 7bit References: <3k8bmskl50p7v5vdri6s30q30105rssn24@4ax.com> To: belspar@voila.fr Content-Type: text/plain; charset=us-ascii X-Complaints-To: newsabuse@remarq.com X-Trace: 962989654 LGTBT6QCL3625D501C uk21.supernews.com Organization: RemarQ http://www.remarQ.com Mime-Version: 1.0 Reply-To: connor_mcdonald@yahoo.com Newsgroups: comp.databases.oracle.misc belspar wrote: > > hi all > > my problem is that i have a function which retrieve me lot of data in > a cursor : > > myfunction(Aparam in integer) return refcursortype ; > > and I want to use it in a select statment like : > > select some,data,a,b > From table > where some = 1 And data in (myfunction(1)) ; > > today i must use this statment : > > select some,data,a,b > From table > where some = 1 And data in (select ... from othertable where > otherdata in selec( ...)) ; > > and i use it lot of time with different parameters , so I want to > create a function. > I think the "select" in the "where" has the same type as the cursor > returned by my function no ?? > i use oracle 8i enterprise > > thanks a lot for help > > NB: sorry for my poor english , I'm french define the cursor as a type in a package - then you can share it amongst several pl/sql routines. HTH -- =========================================== Connor McDonald http://www.oracledba.co.uk We are born naked, wet and hungry...then things get worse