14-07-2012, 11:54 AM
Logical operator
Logical operator.unit-2 DBMS.ppt (Size: 66 KB / Downloads: 22)
OR operator
Ex:- list the employees details having grades ‘E2’ or E3 from table employee
Syntax:- select * from employee where (grade = ‘E2’ or grade =‘E3’);
AND
Ex:- to list all the emp details having grades as E4 but with gross <9000
Syntax:- select * from employees where (grade =‘E4’ and gross <9000);
NOT
List all the employees details whose grades are other than G1.
Syntax:- Select * from employees where (not grade =G1);
Select * from supplier where city<> delhi;
Searching for Null
IS NULL
Write a query to display employee name,salary and deptno who are not getting commission.