KEMBAR78
sql6 | PDF
0% found this document useful (0 votes)
1 views1 page

sql6

The document provides SQL queries using logical operators to retrieve customer data. It includes examples for the AND operator to find customers from the USA with a score greater than 500, the OR operator for customers from the USA or with a score greater than 500, and the NOT operator for customers with a score not less than 500. Each query is accompanied by a brief description of its purpose.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
1 views1 page

sql6

The document provides SQL queries using logical operators to retrieve customer data. It includes examples for the AND operator to find customers from the USA with a score greater than 500, the OR operator for customers from the USA or with a score greater than 500, and the NOT operator for customers with a score not less than 500. Each query is accompanied by a brief description of its purpose.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

LOGICAL OPERATOR

Ques:- Retrieve all customers who are from USA


and have a score grater than 500. */

SELECT *
FROM customers
WHERE country = 'USA' AND score > 500

OR OPERATOR

Ques:- Retrieve all customers who are from USA


and have a score grater than 500.
SELECT *
FROM customers
WHERE country = 'USA' OR score > 500

NOT OPERATOR
Ques:- Retrieve all customers with a score not less
. than 500
SELECT *
FROM customers
WHERE NOT score < 500

You might also like