| Oracle FAQ | Your Portal to the Oracle Knowledge Grid | |
Home -> Community -> Usenet -> c.d.o.server -> Re: Cursors : parameters vs bind variables
In terms of parsing, they are pretty much identical, as a parameter passed to a cursor is a bind variable by the time the SQL hits the database.
There are some overheads in the PL/SQL layer relating to scope checking - i.e. Oracle making sure that a variable that magically appears in the middle of a cursor is legal at compile time and some overhead for stepping backwards through stacks (or possibly heaps) to locate it at run-time.
-- Regards Jonathan Lewis http://www.jlcomp.demon.co.uk Next Seminar dates: (see http://www.jlcomp.demon.co.uk/seminar.html ) ____USA__________November 7/9 (Detroit) ____USA__________November 19/21 (Dallas) ____England______November 12/14 The Co-operative Oracle Users' FAQ http://www.jlcomp.demon.co.uk/faq/ind_faq.html Le JeanMimi wrote in message ...Received on Sun Nov 03 2002 - 13:57:33 CST
>I'm reading the Oracle PL/SQL User's Guide and i've got a small
>question with cursors.
>
>What are the differences between :
>- cursors using bind variables
>- passing cursor parameters
>(- or even cursors referencing variables in the current pl/sql scope)
>
>in terms of parsing, performance, concepts ...
>
>They seems very similar to me but i feel that bind variables are more
>powerful.
>Can I have some explanations ? (sorry if it's a dumb question)
>
>TIA
>
>Jean-Michel
![]() |
![]() |