Search This Blog

Thursday, October 27, 2011

What Is In Operator in Sql with Example


Stu_IdStu_NameStu_Class
1Komal10
2Ajay10
3Rakesh10
4Bhanu10
5Santosh10
1Komal10


SQL IN Query

The given below Query return you the records from table stu_table specifying multiple value in Stu_Name containing name 'komal' and 'Rakesh'.

SELECT Stu_Id, Stu_Name, Stu_Class FROM Stu_Table WHERE Stu_Name IN('Komal', 'Rakesh')

Result

Stu_IdStu_NameStu_Class
1Komal10
3Rakesh10
1Komal10

No comments:

Post a Comment