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 the use of & in pl sql?

1046


Mention what is the use of function "module procedure" in pl/sql?

1049


What is a rank in sql?

963


explain the delete statements in sql

1058


How to read/write files from pl/sql?

1035


How do you create an update query?

962


how to include comments in sql statements? : Sql dba

955


What do you mean by query optimization?

1002


How do I order columns in sql?

1007


How is pl sql different from sql?

1089


What are stored procedures used for?

1002


what are the authentication modes in sql server? : Sql dba

1063


what is 'mysqlcheck'? : Sql dba

1014


Can we rename a column in the output of sql query?

993


how to drop an existing view in mysql? : Sql dba

1060