1.
Which of the following variable declarations is correct in PL/SQL?
2.
The following PL/SQL query is categorized under ____________:
DECLARE
updated_rows number(2);
BEGIN
UPDATE I_EMPLOYEES SET salary = salary + 1000 WHERE EMPLOYEE_ID = 3;
IF SQL % NOTFOUND THEN
dbms_output.put_line('No employee found');
ELSEIF SQL % FOUND THEN
updated_rows: = SQL % ROWCOUNT;
dbms_output.put_line('Updated rows = ' || updated_rows);
END IF;
END;
3.
The following PL/SQL query is categorized under ____________:
DECLARE
CURSOR c_emp IS SELECT * FROM i_employees;
temp I_EMPLOYEES % rowtype;
BEGIN
OPEN c_emp;
LOOP
FETCH c_emp into temp;
dbms_output.put_line(temp.employee_id || ' ' || temp.first_name || ' ' || temp.last_name);
EXIT WHEN c_emp % NOTFOUND;
END LOOP;
CLOSE c_emp;
END;
4.
The below sample query is an example of which of the following?
begin
v_name: = get_lastname(33);
end;
5.
In PL/SQL. which of the following operators is used to display records if at least one of the operands is true?
6.
What is the output of the following PL/SQL query:
select NVL2(987456, 'OK', 'NOT OK') from dual;
7.
Which of these loops is used in the following PL/SQL query:
LOOP
v_count: = 10;
IF v_count = 10 THEN
EXIT;
END IF;
END LOOP;
8.
Which of these loops is used in the following PL/SQL query:
LOOP
v_count: = v_count + 10;
EXIT WHEN v_count = 11;
END LOOP;
9.
In PL/SQL, which of the following notations is used to get references to the package elements?
10.
Which of the following queries is used to disable triggers in PL/SQL?