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...

suppose we have values like 1 5 7 in a colum.Now we want
numbers like(2 3 4 6) that exists between 1 5 7.How can we
do this using sql query??

Answer Posted / kavitha n

Create Table Missingsquence ( Num Number);

sql > select Num from Missingsquence ;

Missingsquence
--------------
1
5
7

SELECT LEVEL num
FROM DUAL
CONNECT BY LEVEL <= 7
MINUS
SELECT num
FROM missingsquence;

Is This Answer Correct ?    7 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is loop in pl sql?

1034


how many groups of data types? : Sql dba

1020


What is keys and its types?

1069


what is a field in a database ? : Sql dba

1053


what are the advantages of sql ? : Sql dba

1054


Is grant a ddl statement?

894


Is drop table faster than truncate?

985


What is mdb stand for?

1004


When sql appeared?

1086


Is it possible to create the following trigger: before or after update trigger for each row?

1280


What is use of trigger?

928


Is sql developer case sensitive?

994


What is the difference between view and stored procedure?

959


Why is sql better than hql?

981


How do I find duplicates in the same column?

1076