SQL: Select all columns against a specified condition
SQL Basic Select Statement : Exercise-10 with Solution.
Write a SQL statement to display all the information for those customers with a grade of 200.
Sample table: customer
Sample Solution :
SELECT *FROM customer WHERE grade=200;
Output of the Query:
customer_id cust_name city grade salesman_id 3007 Brad Davis New York 200 5001 3005 Graham Zusi California 200 5002 3003 Jozy Altidor Moscow 200 5007
Pictorial presentation :
Have another way to solve this solution? Contribute your code (and comments) through Disqus.
Previous: Write a query to display names and city of salesman, who belongs to the city of Paris.
Next: Write a sql query to display the order number followed by order date and the purchase amount for each order which will be delivered by the salesman who is holding the ID 5001.
What is the difficulty level of this exercise?