Lab Mannual Part 2 DBMS
Lab Mannual Part 2 DBMS
List of Experiment
1. Installing oracle/ MYSQL
2. Creating Entity-Relationship Diagram using case tools.
3. Writing SQL statements Using ORACLE /MYSQL:
a) Writing basic SQL SELECT statements.
b) Restricting and sorting data.
c)Displaying data from multiple tables.
d)Aggregating data using group function.
e) Manipulating data.
e) Creating and managing tables.
4. Write SQL queries using logical operators (=, <, >, etc.)
5. Write SQL queries using SQL operators (between..end, IN(List), Like, IS NULL and also
with negating expressions.
6. Write SQL query using character, number and date data types.
7. Write SQL queries using group by and having clause.
8. Write SQL queries for UNION, INTERSECT and MINUS.
9. Write SQL queries for extracting data from more than one table (EQUI JOIN, NON EQUI
JOIN, Outer Join).
10. Write SQL queries for sub queries, nested queries.
Maharishi University of Information Technology
Experiment No. 3
Objective: Writing SQL statements Using ORACLE /MYSQL:
e) Manipulating data
UPDATE table
SET column = value [, column = value ...]
[WHERE condition]
[WHERE condition];
Experiment No. 4
Objective: Write SQL queries using logical operators (=, <, >, etc.)
Create table emp
(emp_name varchar2(20),
emp_no number(5),
emp_dept varchar2(10),
salary number(10,2));
Experiment No. 5
Objective: Write SQL queries using SQL operators (between..end, IN(List),
Like, IS NULL and also with negating expressions.
Experiment No. 6
Objective: Write SQL query using character, number and
date data types.
Create table emp
(EID char(10),
ENAME char(25),
DOJ datetime,
SALARY numeric(9, 2));
Experiment No. 7
Objective: Write SQL queries using group by and having
clause.
A1 STROAD 15000
A2 MANDICHOWK 16000
A3 KATGHAR 18000
A4 CIVILLINES 21000
. . .
. . .
. . .
. . .
A20 STROAD 17000
Experiment No. 8
Objective: Write SQL queries for UNION, INTERSECT and MINUS.
The number of columns and the data types of respective columns being selected must be identical.
Select distinctcust_no
From acct_fd_cust_dtls
Where acct_fd_no LIKE ‘CA%’
Or acct_fd_no LIKE ‘SB%’
Maharishi University of Information Technology
INTERSECT
Select distinct cust_no
From acct_fd_cust_dtls
Where acct_fd_no LIKE ‘FS%’;
Experiment No. 9
Objective: Write SQL queries for extracting data from more than one table (EQUI JOIN, NON
EQUI JOIN, Outer Join).
Experiment No. 10
Objective: Write SQL queries for sub queries, nested
queries.
Find out all customers having same names as the employees.
List accounts alongwith the current balance, the branch to which it belongs and the average balance of
the branch, having a balance more than the average balance of the branch, to which the count belongs.