MCQs > Database Management > Oracle PL/SQL 9i > Examine the code given below: Declare cursor emps is select Empno,ename,sal,deptno,job from emp; begin for rec in emps loop open emps; dbms_output.put_line(rec.empno||rec.ename||rec.sal||rec.deptno||rec.job); end loop; end; / What is wrong in above declaration?

Oracle PL/SQL 9i MCQs

Examine the code given below:
Declare
cursor emps is
select Empno,ename,sal,deptno,job from emp;
begin
for rec in emps loop
open emps;
dbms_output.put_line(rec.empno||rec.ename||rec.sal||rec.deptno||rec.job);

end loop;
end;
/
What is wrong in above declaration?

Answer

Correct Answer: There is no need to open cursor in the for loop 

Explanation:

Note: This Question is unanswered, help us to find answer for this one

Oracle PL/SQL 9i Skill Assessment

Overall Skill Level-Poor

Your Skill Level: Poor

Retake Quizzes to improve it

More Oracle PL/SQL 9i MCQ Questions

search

Oracle PL/SQL 9i Skill Assessment

Overall Skill Level-Poor

Your Skill Level: Poor

Retake Quizzes to improve it