Latest Post

Friday, 16 September 2016

AND Sql Operator (Keyword)

AND
The AND is logical operator and used to filter the records on one or more condition.
Syntax: The following is the basic syntax of AND keyword
SELECT column1, column2 FROM your_table_name WHERE Condition1 AND Condition2
Example:

Id
Name
Age
Address
Department
Gender
1
Alok Kumar Singh
30
IN
IT
Male
2
Tomas Paul
45
NZ
IT
Male
3
Cristomfer Dee
24
AU
HR
Female
4
Niel Macengi
55
US
BPO
Female

The following SQL statement selects all employee of "IT" department and gender is "Male"
USE SQLCLR
GO
SELECT * FROM EMPLOYEE WHERE Department='IT' AND Gender='Male'

GO

Id
Name
Age
Address
Department
Gender
1
Alok Kumar Singh
30
IN
IT
Male
2
Tomas Paul
45
NZ
IT
Male





Government Jobs