Special comparison operator used in where clause-dml, Database Management System

Assignment Help:

Special comparison operator used in where Clause

a.   between. ...and...It gives range among two values (inclusive)

Example:

SELECT ENAME, SAL FROM EMP

WHERE SAL BETWEEN 1000 AND 1500;

b.   In (list): match any of a list of values

Example:

SELECT EMPNO, ENAME, SAL, MGR FROM EMP

WHERE MGR IN (7902, 7566, 7788);

7902, 7566, and 7788 are Employee numbers c.      Like: match a character pattern

  • % indicates zero or many characters
  • Like operator is used only with char and Varchar2 to match a pattern
  • _ indicates one character
  • Combination of % and_can also be used.

Example:

(I)  List the names of employees whose name begins with 's' SELECT ENAME FROM EMP

WHERE ENAME LIKE 'S%';

 (II)    List the ename finished with's'

SELECT ENAME FROM EMP WHERE ENAME LIKE '%S';

(III)   List ename having I as a second character

SELECT ENAME FROM EMP WHERE ENAME LIKE '_I%';

d. Is null operator

Example:

 to search employee whose manage-id is not specified

SELECT ENAME, MGR FROM EMP WHERE MGR IS NULL;


Related Discussions:- Special comparison operator used in where clause-dml

Decomposition, properties of derirable decomposition

properties of derirable decomposition

DW, #ques Define a job scheduling strategy that will meet business requirem...

#ques Define a job scheduling strategy that will meet business requirement of reporting availability by 6am CST for the following cubes? Show the job scheduling dependencies in a p

Assign, #quesDefine a job scheduling strategy that will meet business requi...

#quesDefine a job scheduling strategy that will meet business requirement of reporting availability by 6am CST for the following cubes? Show the job scheduling dependencies in a pi

Prepare an erd for the scenario, Question: (a) Prepare an ERD for the s...

Question: (a) Prepare an ERD for the scenario given below. (b) Convert the ER diagram produced in (a) above into its physical design. You have to choose an appropriate Pri

Define hot backup, Hot Backup: Some sites cannot terminate the database wh...

Hot Backup: Some sites cannot terminate the database while creating a backup copy of the files. The cold backup is not a reliable option. So different kinds of backing up database

Hass, waht is a repeating group?

waht is a repeating group?

Database for Managers, I have to create a database about anything of my cho...

I have to create a database about anything of my choice. It has to contain 4 queries, and 4 forms. It can be anything as simple as a shoe inventory with numbers - is this a service

3-schema architecture, Gyan Gurukul is a software company that provides sof...

Gyan Gurukul is a software company that provides software related solution. Ashutosh Dubey who is the director of Gyan Gurukul want a three-level schema architecture for the Gyan G

Explain the uses of deadlock, Explain the uses of deadlock It will lea...

Explain the uses of deadlock It will lead to deadlock since this is the only place where incoming acknowledgements are processed. Without this code, sender will keep timing ou

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd