Está en la página 1de 2

SAMPLE PAPER-III

Class – XI, CS, PT II 2019


M.M. – 50 Time Duration – 90 Minutes
_________________________________________________________________
Instruction: - Attempt all the question. Read carefully and answer accordingly.

On the basis of above relation EMPL write correct SQL query to perform following
task.
1 Create database Employee. 1
2 Use databaseEmployee. 1
3 Drop table EMPL if exists. 1
4 Create table EMPL has following attributes and their type. 2
empno decimal, enamevarchar, job varchar, mgr decimal, hiredate date, sal decimal,
comm decimal, deptno decimal,
5 Insert above said values in EMPL table. 2
6 Display all the records (all coloumns) from the table EMPL. 1
7 Display EmpNo and EName all all employees from the table EMPL. 1
8 Display Ename, Sal and Sal added with Comm from table EMPL. 1
9 Display employee name, salary and department number who are not getting 1
commission from table EMPL.
10 Display employee number, name sal and sal*12 as annual salary whose 2
commission is not NULL from table EMPL.
11 List all department number in table EMPL. 1
12 List all unique department numbers in table EMPL. 1
13 List details of all clerks who have not been assigned departments as yet. 1
14 List the details of those employees who have four lettered names. 1
15 List the details of all employees whose salary is between 25000 – 40000. 1
16 How many jobs types are offered to employees? 1
17 List the details of those employees who earn more commission than their salaries. 1

1|Page
18 Display the name, job title and salary of employee who do not have manager. 1
19 Display the name of the employee whose name contains ‘A’ as third alphabet. 1
20 Display the name of employee whose name contains ‘T’ as the last alphabet. 1
21 Display the name of employee who is having ‘L’ as any alphabet of the name. 1
22 Display details of all employees in reverse order of attributes from table EMPL. 1
23 Display the structure of table EMPL. 1
24 Display output in the following format. 2
Mr./Mrs./Ms. <ename> is working as <job> from <hiredate> .
25 Display details of employee whose job is clerk and salary is more than 1000. 1
26 Display details of employee whose job is in the list (‘CLERK’, ‘SALESMAN’). 1
27 List the details of all employees whose salary is not between 25000 – 40000. 1
28 Display details of employee whose job is not in the list (‘MANAGER’, 1
‘ANALYST’).
29 Display the name of the employee whose name does not contains ‘A’ as third 1
alphabet.
30 List the details of all employees in ascending order of name. 1
31 List the details of all employees in descending order of salary. 1
32 How to insert data from another table EMPL1 into table EMPL. 1
33 What will be the output of following SQL command. 5
Select char(70);
Select ltrim (‘ RDBMS MYSQL’);
Select round(15.193,1) “Round”;
Select dayofyear(‘2020-02-13’);
Delete from empl;
34 Drop table EMPL. 1
35 Explain following terms. 3
Relation, domain, tuple, attribute, degree, cardinality
36 Differentiate primary key and unique key. 2
37 Compare DDL and DML. 2
38 Differentiate alter and update command. 2

2|Page

También podría gustarte