where clause in MYSQL by R4R Team

What is MYSQL WHERE clause?
-MySQL WHERE Clause is used with SELECT, INSERT, UPDATE and DELETE clause to filter the results.
-It specifies a specific position where you have to do the operation.

Syntax:
WHERE conditions;

We have a table 'library'

SELECT * FROM library;

Id Stud_name Book_id
1 Aman 234
2 Ram 24
3 Ramesh 81
4 John 567
5 Sita 67

Now, we filter our data, and display only those record whose Id is greator than 2

SELECT * FROM library WHERE Id>2;

Id Stud_name Book_id
3 Ramesh 81
4 John 567
5 Sita 67




Leave a Comment: