If there are 1 to 100 numbers in a table and in that 100
numbers some 10 numbers are deleted.I want to find out the
missing numbers between 1 to 100 by pl/sql how?
Answer Posted / mani
DECLARE
l_id NUMBER;/* Temp IS TABLE AND ID IS COLOUMN HAVING
Numbers*/
BEGIN
FOR I IN 1..100 LOOP
SELECT COUNT(*) INTO l_id FROM temp WHERE id=I;
IF (l_id = 0) THEN
DBMS_OUTPUT.PUT_LINE(I);
ELSE
NULL;
END IF;
END LOOP;
END;
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
How long does it take to learn pl sql?
What operators deal with null?
Why select is used in sql?
What do you understand by pl/sql packages?
What are basic techniques of indexing?
What is coalesce in sql?
Can we commit in trigger?
What is the difference between unique and primary key constraints?
Is it important to partition hard disk?
Is clustered index a primary key?
Explain constraints in sql?
What is the use of sqldataadapter?
Is it possible to pass parameters to triggers?
Write a query to find the names of users that begin with "um" in sql?
What is the maximum number of triggers, you can apply on a single table?