Professional Documents
Culture Documents
Dms 22319 Microproject
Dms 22319 Microproject
Annexure-II
Micro-Project
Team Members:
Om Ghugare (30)
Abhishek Chaudhari (31)
Suyash Nangare (32)
Rohan Khachane (33)
Micro-Project Proposal
Execute queries using SELECT command with WHERE and HAVING clause:
1.0 Rationale
Database Management Systems (DBMS) are vital components of modern information systems.
Database applications are pervasive and range in size from small in-memory databases to terra
bytes or even larger in various applications domains. The course focuses on the fundamentals of
knowledgebase and relational database management systems, and the current developments in
database theory and their practice.
A) SELECT COMMAND -
B) WHERE CLAUSE -
C) HAVING CLAUSE –
A) SELECT COMMAND -
Syntax:
Select *
from {table_name}
order by {unique_key}
Example:
SELECT * FROM
( SELECT
ROW_NUMBER() OVER (ORDER BY sort_key ASC) AS row_number,
columns
FROM tablename
) AS foo
WHERE row_number <= 11;
B) WHERE CLAUSE -
Syntax:
Example:
SELECT * FROM
Customer
WHERE customer_id = 101;
C) HAVING CLAUSE -
A HAVING clause in SQL specifies that an SQL SELECT statement should only return rows where
aggregate values meet the specified conditions. It was added to the SQL language because
the WHERE keyword could not be used with aggregate functions.
The HAVING clause filters the data on the group row but not on the individual row.
To view the present condition formed by the GROUP BY clause, the HAVING clause is used.
Syntax:
SELECT column_name(s)
FROM {table_name}
WHERE condition
GROUP BY column_name(s)
HAVING condition
Example:
b. Displaying DEPARTMENT:
Select * from DEPARTMENT;
Executing QUERIES using WHERE and HAVING CLAUSE
2. Abhishek Chaudhari - 42
3. Suyash Nangare - 43