Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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


Please Help Members By Posting Answers For Below Questions

What is difference between sql function and stored procedure?

941


Why do we need view in sql?

932


Explain spool.

1111


Why coalesce is used in sql?

917


what is the stuff function and how does it differ from the replace function? : Sql dba

989


What is the difference between truncate and drop statements?

1083


What are the built in functions of sql?

981


What does 0 mean in sql?

911


What is the difference between execution of triggers and stored procedures?

1050


What are different functions in sql?

897


Can we insert in view in sql?

1002


I need a function for a train ticket reservation please answer it thanks in advance

957


What is execute immediate?

1004


Why we use sql profiler?

912


What is your daily office routine?

2216