bing
Flat 10% & upto 50% off + Free additional Courses. Hurry up!
×
UPTO
50%
OFF!

AND & OR Clause

 

  • AND Clause:

It is used to apply multiple conditions in WHERE clause. The result will be displayed only when all the conditions are true. The syntax is as follows:

Syntax:

SELECT column1, column2….

FROM Table_name

WHERE [condition1] AND [condition2] ….[conditionN];

 

Example:

Display the name of the students whose Age is less than 20 and scores greater than 70.

SELECT Name

FROM Student_details

WHERE marks>70 AND age<20;

 

  • OR Clause:

It is also used to apply multiple conditions but it will fetch the data when any one of the condition is true. The syntax is as follows:

Syntax:

SELECT column1, column2….

FROM table_name

WHERE [condition1] OR [condition2]……. OR [conditionN];

 

Example:

Display the name of the students those are either from jaipur or scores greater than 60.

SELECT Name

FROM Student_details

WHERE City=Jaipur OR Marks>60;

"0 Responses on AND & OR Clause"

100% Secure Payments. All major credit & debit cards accepted Or Pay by Paypal.
top

Sales Offer

  • To avail this offer, enroll before 24th May 2017.
  • This offer cannot be combined with any other offer.
  • This offer is valid on selected courses only.
  • Please use coupon codes mentioned below to avail the offer
offer-june

Sign Up or Login to view the Free AND & OR Clause.