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

use of IN/ANY/ALL

Answer Posted / bunty

IN - used to select multiple rows based on any of the key
provided

SQL - select distinct employeeid from orders where orderid
in ( select orderid from orderdetails where discount >= 10)


ANY - used in case of relational queries to compare result
with any of the key.

SQL - select custID from orders where regionID != "E" and
discount > any (select discount from orders where regionID
= "E" and discount > 3)

ALL - used in case of relational queries to compare result
with all of the keys.

SQL - select custID from orders where regionID != "E" and
discount > all (select discount from orders where regionID
= "E" and discount > 3)

Cheers -
Bunty

Is This Answer Correct ?    11 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

what is dbms? : Sql dba

1037


What is synchronized subquery?

1222


Any attempt to navigate programmatically to disabled form in a call_form stack is allowed?

1149


How do you write an inner join query?

996


what is the difference between primary key and unique key? : Sql dba

1086


What is full join?

1023


what are set operators in sql? : Sql dba

1108


what is self-join? : Sql dba

1244


Mention what are different methods to trace the pl/sql code?

1297


How can check sql version from command line?

1139


which tcp/ip port does sql server run on? : Sql dba

1085


What is dense_rank?

989


what are the differences between char and nchar? : Sql dba

1162


What are commit, rollback, and savepoint?

1049


What is trigger in sql and its types?

1113