Use The Implicit cursor to Query The Department table information Where Deptno is 30.check,if no record was found then print "Record Was Not Found".Else Print Deptname And Ename.Dept table Have Dname Varchar2(20),Deptno Number,EnameVarchar2(20).Please Answer In 2 mins,with in Maximum 15 lines.
Answer Posted / swastik
declare
v_deptno number(2) := &gdeptno;
v_dname varchar2(20);
v_ename varchar2(20);
begin
select deptno, dname, ename into v_deptno, v_dname, v_ename
from dept
where deptno = v_deptno;
dbms_output.put_line(v_deptno|| ' '||v_dname||' '||v_ename);
exception
when no_data_found
then
dbms_output.put_line('record was not found');
end;
/
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
What does := mean in pl sql?
How to download oracle sql developer?
Why do we use set serveroutput on?
How can I speed up sql query?
What is graph sql?
Is there a pl/sql pragma similar to deterministic, but for the scope of one single sql select?
What is pl/sql table? Why it is used?
Can you load data into multiple tables at once? : aql loader
What is natural join in sql?
What is a data manipulation language?
What does (+) mean in sql joins?
How do I remove duplicates in two columns?
How do I view a sql trace file?
What are the disadvantages of not performing database normalization?
What is procedure in pl sql?