0% found this document useful (0 votes)
11 views13 pages

Database Management System Queries

The document contains the midterm project details for a Database Management System course. It lists the members of the group and the reports/queries they will each work on related to a database of salon information records. Each member's section includes the name of 2 reports they will create and the SQL queries and syntax for each report. The goal is to practice different types of queries to retrieve, filter, group, count and order data from the salon database table.

Uploaded by

Peter Cunanan
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views13 pages

Database Management System Queries

The document contains the midterm project details for a Database Management System course. It lists the members of the group and the reports/queries they will each work on related to a database of salon information records. Each member's section includes the name of 2 reports they will create and the SQL queries and syntax for each report. The goal is to practice different types of queries to retrieve, filter, group, count and order data from the salon database table.

Uploaded by

Peter Cunanan
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd

MIDTERM PROJECT

IN
DATABASE MANAGEMENT SYSTEM

SECTION
SBIT-MT3B

MEMBERS:
COLLADO, JHON EDUARDO V.
COMBOY, ERICA MAE S.
CUNANAN, JON PETER S.
DE GUZMAN FERDINAND G.
FERNANDEZ,VINCENT B.
GALLANO, MESHA E.
GARCIA, FERNANDO E.
LERIOS, WYRLO A.
PATINGO, JOHN YVES V.
TABUDLO, MARIA ANDREA PATRICIA T.
VIOLA, JOHN PAUL T.
LIST OF SALON INFORMATION RECORDS
COLLADO, JHON EDUARDO V.
REPORT NAME QUERY SYNTAX
[Link] a querty that the Salon ID order [Link] salon_id
[Link] Of Salon order descended descended. FROM salon_tbl order by salon_id Desc;

[Link] Salon_name,Barangay FROM


2. List of Salon have a letter C in their [Link] a query that will display the Salon_tbl
names Salon name and barangay with the letter WHERE Salon_namE like('%C%');
C
COMBOY, ERICA MAE S.
REPORT NAME QUERY SYNTAX
[Link] of Salon have a letter S in their [Link] a query that will display the SELECT salon_name
names salon name that has have a letter S FROM salon_tbl
WHERE salon_name like ‘%S%;
[Link] a query that will display the
[Link] of Salon that their operating operating hours , monthly income SELECT Operating_hr,Monthly_income
hours and monthly income of salon between salon id number 4 and 8 FROM salon_tbl
between salon id number 4 and 8 Where salon_id between 4 and 8;
CUNANAN, JON PETER S.
REPORT NAME QUERY SYNTAX
[Link] of Salon,Barangay and Telephone Create a query that will display the [Link] Salon_name,Barangay,Tel_no
number of Salon ID from 1 to 5. Salon_name,Barangay and telephone from salon_tbl where salon_id between 1
number from Salon ID 1 to 5. and 5;

[Link] a query that will display the 2. Select Salon_name,Tel_no,email from


[Link] of Salon that their monthly Salon name,Telephone number and email Salon_tbl where monthly_income=25000
income is 25000 at Barangay tandang and their monthly income is equal to and barangay='tandang sora';
sora 25,000 near at tandang sora.
DE GUZMAN FERDINAND G.
REPORT NAME QUERY SYNTAX
[Link] of Salon in barangay [Link] [Link] a query that display
the email starts with letter A Salon/name,barangay and email with the 1. SELECT Salon_name,Barangay,email
have letter A. FROM Salon_tbl WHERE Salon_name
like('%a%') and Barangay in('Baesa');
[Link] of Telephone number in barangay
baesa [Link] a query that display the Select Tel_no,Barangay FROM Salon_tbl
telephone number in baesa. where barangay in('Baesa');
FERNANDEZ VINCENT B.
REPORT NAME QUERY SYNTAX
[Link] of all Salon in barangay sauyo [Link] the all data in sauyo 1. Select *from Salon_tbl where barangay
in ('SAUYO');
[Link] the Expensive Services Spa [Link] a query that will count the
expensive service Spa [Link] count(expensive_service) from
salon_tbl where expensive_service='SPA';
GALLANO, MESHA E.
REPORT NAME QUERY SYNTAX
[Link] of Salon, owner name, barangay [Link] a query that will display the [Link]
that operates in 8 hrs. salon name, owner name and barangay Salon_name,Owner_name,Barangay
that operates in 8hrs. FROM salon_tbl
WHERE operating_hrs in (‘8’);
[Link] of Salon and barangay that their [Link] a query that will display the
monthly income is less than 21,000. salon name and barangay that their 2. SELECT Salon_name,Barangay
income is less than 21000 FROM salon_tbl
WHERE monthly_income >21000;
GARCIA, FERNANDO E
REPORT NAME QUERY SYNTAX
[Link] of Salon that there have a 1. Create a query that will display the [Link] salon_name
haircut and Cellophane salon name that there have a haircut FROM salon_tbl
and cellophane service. WHERE Cheapest_service='haircut' and
expensive_service='cellophane';
[Link] of Salon in Sauyo that has a
haircut and hair rebond in sauyo 2. Create a query that display a Salon [Link] salon_name
name that there have a haircut and FROM Salon_tbl
[Link] sauyo WHERE cheapest_service='haircut' and
expensive_service='rebond' in ('SAUYO');
LERIOS, WYRLO A.
REPORT NAME QUERY SYNTAX
1. Salon name that has letter n on [Link] the barangay name with 3rd 1. Select count(barangay) from salon_tbl
the name. letter "n" in their spelling. where barangay like ('%__n%');

2. Select count(salon_name),monthly_income
2. Count the name of salon with from salon_tbl where monthly_income!=30000
2. Salon that has a monthly income monthly income that is not equal to group by monthly_income;
that’s not equal to 30,000 30000.
PATINGO, JOHN YVES V.
REPORT NAME QUERY SYNTAX
[Link] of salon name district in [Link] a query that will display the [Link] Salon_name,District,Barangay
barangay baesa salon name, district and barangay in FROM salon_tbl
baesa WHERE barangay in (‘BAESA’);

[Link] Salon_name,Owner_name,barangay
[Link] of salon, owner name and [Link] a query that will display the FROM salon_tbl
barangay that the monthly income is salon name, owner name and barangay WHERE Monthly_income >=25000;
more than or equal to 25,000. that the salary income is greater than
or equal to 25,000.
TABUDLO, MARIA ANDREA PATRICIA T.
REPORT NAME QUERY SYNTAX
1. List of barangay that has have salon. [Link] a query that will display each 1. SELECT barangay,COUNT(barangay)
barangay in groups and their count. FROM Salon_tbl GROUP BY barangay
ORDER BY COUNT(barangay) DESC;

[Link] salon_name,montly_income
[Link] of Salon and list of there monthly [Link] a query that will display FROM salon_tbl ORDER BY
income. all the salon name and their monthly monthly_income DESC;
income in a descending order.
VIOLA, JOHN PAUL T.
REPORT NAME QUERY SYNTAX
1. List of Salon Information that the 1. Create a query that will display all [Link] Salon_ Name
monthly income is less than or equal to salon information and their monthly *FROM Salon_tbl
30,000. income are less than 30,000. WHERE monthly_income <=30000;

2. List of salon name that their 2. Create a querty that will display a [Link] Salon_name
cheapest service is not haircut. salon name and cheapest service is not FROM Salon_tbl
haircut. WHERE cheapest_service !=’haircut’;

You might also like