0% found this document useful (0 votes)
11 views

TestQuestionPapers OracleApp

Oracle questions

Uploaded by

sairamram2310
Copyright
© © All Rights Reserved
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views

TestQuestionPapers OracleApp

Oracle questions

Uploaded by

sairamram2310
Copyright
© © All Rights Reserved
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 2

Module Test (Practical): Coding Test on UNIX and Oracle (SQL & PL/SQL)

Max Marks: 70
Duration: 2.5 Hrs

Assessment Parameters
 Solution Completeness (all requirements addressed) – 20 %
 Working solution for each requirement – 40 %
 Comments – 20%
 Coding standards – 20 %
_____________________________________________________________________________

Section 1 – UNIX [Marks: 15]

Q1. Give commands for the following : [Marks 10]

1. Write the command to list the hidden files along with all files and directories.
2. Write a command to know, what are process running on server.
3. Write a command to create directory
4. Write a command to compare to two files
5. What is tree command?
6.Write a command to copy one directory to another location
7. Write a command to zip a file and unzip a file
8.Write a command to display current running process
9.Write a command to kill the jobs, those are working in background
10. Write a command to
i. to save and quit command in Vi editor
ii. quit without saving a file in Vi editor
Q2. Write shell script for the following: [Marks 5]
1. Write a shell script program to accept two numbers and display add, multiply of two
numbers.
2. Write shell script program to accept filename. Check for the input filename exits in
filesystem or not and give a appropriate message as output.

Section 2 – Oracle [Marks 55]

Q1. Write queries for the following


(Solve any 4 Queries out of the given 5.) [Marks 20]

1. Display the names of employees who joined after ’01-JAN-99.


2. Display the Deptno where there are no employees.
3. Display empno,first_name,hiredate,current date & experience (in Months) in the
ascending order of the experince
4. Display First_Name,Last_name, Job, Salary of the employees in the department with
the highest average salary
5. Display the employee name(first+last name), salary, department_id, commision_pct,
increased salary (if employee in (JOB_ID) IT 10%, FI 12% and others no increase) as
NEW SALARY.
_____________________________________________________________________
Page 1 of 2

Capgemini Public
Module Test (Practical): Coding Test on UNIX and Oracle (SQL & PL/SQL)

Q2. 1. Create a procedure to accept department_id and raise amount as input. [Marks 10]
Check if job is clerk and salary is less than 5000 then give raise and update table
employees. Output will be the updated salaries.
2. write a procedure to display all information of EMPLOYEES table. Use
DBMS_OUTPUT.
.
Note: Take care of necessary validations and handle user and system defined exceptions

Q3. a. Write a function to accept the employee_id and return experience : [Marks 15]
In years with minimum 3 decimal ?

b. Write a database trigger to stroe the username ,type of transaction ,date of


transaction and time of transaction of table employees into the table EMP_LOG

c. Write a database trigger store the deleted data of EMPLOYEES table in EMPDEL
table.

Note: Take care of necessary validations and exception handling

Solve the below mentioned Questions [Marks 10]

Q4. Write an anonymous single PL/SQL block to perform the following task:
Accept department as Input. Using FOR UPDATE and also CURRENT OF clause with
CURSORS, update the table employees and obtain the output of OLDSAL, NEWSAL
with their names, job and department for employees whose job is SH_CLERK or
SA_CLERK by 10% and 20% respectively.

________________________________________________________________________
Page 2 of 2

Capgemini Public

You might also like