Tuesday, November 11, 2008

What WHERE CURRENT OF clause does in a cursor

What WHERE CURRENT OF clause does in a cursor? 
LOOP
SELECT num_credits INTO v_numcredits FROM classes
WHERE dept=123 and course=101;
UPDATE students
FHKO;;;;;;;;;SET current_credits=current_credits+v_numcredits
WHERE CURRENT OF X;

There is a string 120000 12 0 .125 , how you will find the position of the decimal place? 
INSTR('120000 12 0 .125',1,'.')
output 13

What are different modes of parameters used in functions and procedures? 
-IN -OUT -INOUT

How you were passing cursor variables in PL/SQL 2.2? 
In PL/SQL 2.2 cursor variables cannot be declared in a package.This is because the storage for a cursor variable has to be allocated using Pro*C or OCI with version 2.2, the only means of passing a cursor variable to a PL/SQL block is via bind variable or a procedure parameter.



No comments:

Post a Comment

Thanks to given comments.......

My Blog List