SlideShare une entreprise Scribd logo
1  sur  23
Télécharger pour lire hors ligne
1
INDOOR MAP PROJECT (ROOMS): CARNEGIE LIBRARY
JASH MEHTA
IST 659 FINAL PROJECT REPORT
2
Table of Contents
Project Summary ……………………………………………………..3
Tables and Attributes ……………………………………………………..5
Entity Relationship Diagram ……………………………………………………..7
Business Rules …………………………………………………….10
Database Infrastructure …………………………………………………….10
SQL Scripts for Creating
and Inserting Sample Data
…………………………………………………….10
Major Data Questions …………………………………………………….16
Forms and
Reports(Interfaces)
…………………………………………………….18
Triggers …………………………………………………….22
3
Summary:
The resources of the Carnegie include rooms that a SU user could use at the library.
For instance, there are rooms like Offices, Stack Area, Classrooms, Computer Lab,
Computer Cluster.
All rooms have resources such as chairs & table and technology. Classrooms can be
booked by faculty.
Therefore if faculty wants to know which rooms has sufficient capacity then the
faculty can log into the app to find out about the room he/she wants to book.
The resources can be located in a room or outside a room. These resources are
classified based on resource types and also based on the different levels they are
located on.
Supposedly, other resources include dust bins, elevators, exits and entrances in the
Carnegie Library. User (student or faculty) can log into the SU Indoor Map to find out
these other resources.
The scope of my project is limited to identify the rooms and other resources and
their locations at Carnegie so that these details can be fetched by the SU Indoor
Outdoor app.
Major Data Question
The App will be used by two kind of users
 SU students and faculty
 Database administrator
Why would SU students and faculty query the database?
Faculty has the privilege to book rooms in Carnegie Library therefore if any professor
would like to know information regarding the rooms then the database would be
queried
4
Students would like to locate the rooms and respective events in the room. Also,
students & faculty would like to locate the other resources such as drinking fountain,
washrooms, entrance, exits and elevators.
Why would database administrator query the database?
The database administrator would query the database in the event of finding out the
current status of any room or event. Administrator would like to query in order to
update the database. For example, if the semester changes and the events in the
room needs to be changed then it responsibility of the administrator to change it.
Also, if there is any reconstruction or reordering of any of the rooms then the
administrator must make changes in the database.
5
Tables & Attributes
Database object & Attributes Description
User User of the SU indoor Map
PK SUID
UserFirstName
UserLastName
Age
Email
Gender
UserType
Primary Key: Identifies the user uniquely
User’s First Name
User’s Last Name
Age of the user
SuEmail of the user
Gender of the user
Faculty or Student
Rooms Stores Information about all the rooms
PK RoomNumber
Department
Floor
RoomType
Timings
No_Of_Projectors
No_Of_Screens
NoOfChairs
NoOfTables
RoomAccess
Room Type
PK: Identifies the room uniquely
Under which department does the room
come
On which floor is the room located
Office, Classroom, Computer Lab etc
Opening and Closing Hours
Number of resources in the rooms:
Number of projectors, screens, chairs
and tables
Private or Public
Discriminator: Classroom(CR),
ComputerLab(CL), Office (O)
Other Resources Stores other resources such as
washrooms, bins, drinking fountain,
elevators, entrance and exits
PK ResourceID
FK SUID
ResourceName
Floor
Unique ID for resources to identify
resources
SUID taken as foreign key from the User
Table
Vending Machine, Washroom, Dustbin
Floor on which the resource is located
UserRoom Bridge table between user and Rooms
as it is many to many relationship
between user and rooms
6
PK URid
FK SUID
FK RoomNumber
Start Time
End Time
Date
Uniquely identifies the booking for the
user and room
Foreign key from user table
Foreign key from Rooms table
Start time the room booked
End time of the room booked
The date for which room is booked
Computer Lab Stores Information about all the
computers in the room
PK,FK RoomNumber
NoOfComputers
NameOfPrinter
TypeOfPrinter
NameOfScanner
TypeOfScanner
Primary key as well as foreign key to
implement disjoint logic
Number of Computers
Name of the printer
Brand/Company of the printer
Name of the Scanner
Brand/Company of the scanner
Classroom Stores information regarding the
classrooms
PK, FK RoomNumber
FK ClassID
Primary key as well as foreign key to
implement disjoint logic
Class Stores information regarding the event
occurring in the classroom
PK ClassID
URid
School Year
Semester
Uniquely identifies the class which is
being conducted in the classroom
URid as foreign key from UserRoom
bridge table
The school year: For example 2016,
2017
Fall, Spring, Summer
Office Stores information regarding the
person and the contact in the office
PK, FK RoomNumber
PersonIncharge_FirstName
PersonIncharge_LastName
ContactNumber
Primary key as well as foreign key to
implement disjoint logic
First Name of the person
Last Name of the person
Phone number of the office
7
Entity Relationship Diagram
Visio
8
SQL
9
Access
10
Business Rules
 Many users can use/search for many rooms
 A user of the App may search for one or many other resources
 The rooms are complete disjoint entities. A room can be a computer lab, computer cluster,
classroom, office or a stack area
 One classroom can have one class at a given time
Database Infrastructure:
The database infrastructure is based on client-server model. SQL server is used as the database engine
and access is used as the interface design tool. Data is inserted, deleted, updated and queried from the
SQL server database with the help of forms on Access. Useful data stored on SQL database can also be
viewed with the help of reports generated through access.
SQL Scripts for Creating and Inserting Sample Data:
NOTE: I am giving only one insert script for each table rest of the data was inserted by access forms
CREATE TABLE CUSer
(
SUID CHAR(10)NOT NULL,
UserFirstName Varchar(30),
UserLastName Varchar(30),
UserAge INTEGER ,
UserEmail varchar(20),
UserGender Varchar(2),
User_Type Varchar(30),
CONSTRAINT SUID_PK PRIMARY KEY (SUID)
);
INSERT INTO CUSer Values
('12345678','Sachin','Tendulkar','44','saten@syr.edu','M','Faculty')
11
CREATE TABLE CROOMS
(
RoomNumber Char(5) NOT NULL,
Department varchar(30),
CFLoor char(2) ,
Timings varchar(20) ,
No_Of_Projectors INTEGER,
No_Of_Screens INTEGER,
No_Of_Chairs INTEGER,
No_Of_Tables INTEGER,
Capacity INTEGER,
RoomAccess Varchar(30),
RoomType Varchar(30) NOT NULL CHECK (RoomType In ('CL','CR','O')),
CONSTRAINT RoomNumber_PK PRIMARY KEY (RoomNumber)
);
INSERT INTO CROOMS Values ('C108','ABC','2','8 am - 5pm',1,1,20,3,23,'public','CR')
CREATE TABLE Resources
(
ResourceID Varchar(30) NOT NULL,
12
SUID CHAR(10) NOT NULL,
ResourceName Varchar(30),
CFLoor char(2),
CONSTRAINT ResourceID_PK PRIMARY KEY (ResourceID),
CONSTRAINT Resources_FK_SUID FOREIGN KEY (SUID) References CUSer(SUID)
);
INSERT INTO Resources Values ('VM103','12345678','Vending Machine','1')
CREATE TABLE UserRoom
(
URid Varchar(15) NOT NULL,
SUID CHAR(10) NOT NULL,
RoomNumber Char(5) NOT NULL,
URSTime Varchar(30),
URETime Varchar (30),
URDATE Varchar (30),
CONSTRAINT URid_PK PRIMARY KEY (URid),
CONSTRAINT UserRoom_FK_SUID FOREIGN KEY (SUID) References CUser(SUID),
CONSTRAINT UserRoom_FK_RoomNumber FOREIGN KEY (RoomNumber) References CROOMS(RoomNumber)
);
INSERT INTO UserRoom Values ('15','10001','c201','8 am', '9 am', 'May')
13
Create table Class
(
classID Varchar(30) NOT NULL,
URid Varchar(15) NOT NULL,
SchoolYear Varchar(30),
Semester Varchar(30),
CONSTRAINT Class_PK PRIMARY KEY (classID),
CONSTRAINT Class_FK_URid FOREIGN KEY (URid) References UserRoom(URid)
);
INSERT INTO Class Values ('c15','15','2016','Spring')
CREATE TABLE ClassRoom
(
RoomNumber Char(5)NOT NULL,
classID Varchar(30) NOT NULL,
14
CONSTRAINT RoomNumber_PK2 PRIMARY KEY (RoomNumber),
CONSTRAINT ClassRoom_FK_RoomNumber FOREIGN KEY (RoomNumber) References
CROOMS(RoomNumber),
CONSTRAINT ClassRoom_FK_classID FOREIGN KEY (classID) References Class(classID),
);
INSERT INTO ClassRoom Values ('c201','c15')
CREATE TABLE Office
(
RoomNumber Char(5)NOT NULL,
PersonInCharge_FNAME Varchar(30) ,
PersonInCharge_LNAME Varchar(30) ,
PhoneNumber Varchar(30),
CONSTRAINT RoomNumber_PK3 PRIMARY KEY (RoomNumber),
CONSTRAINT Office_FK_RoomNumber FOREIGN KEY (RoomNumber) References CROOMS(RoomNumber),
);
15
CREATE TABLE ComputerLab
(
RoomNumber Char(5) NOT NULL,
No_Of_Computer INTEGER,
No_Of_Printer INTEGER,
Name_Of_Printer varchar(30),
No_Of_scanner INTEGER,
Name_of_scanner varchar(30),
CONSTRAINT RoomNumber_PK1 PRIMARY KEY (RoomNumber),
CONSTRAINT ComputerLab_FK_RoomNumber FOREIGN KEY (RoomNumber) References
CROOMS(RoomNumber)
);
INSERT INTO ComputerLab Values ('Cl102',45,2,'HP Laser Jet', 45, 'Hp')
16
Major Data Questions
-User can know how many classrooms, offices, computer lab are on each floor
SELECT Count(CROOMS.RoomNumber) AS CountOfRoomNumber, CROOMS.RoomType, CROOMS.RoomAccess,
CROOMS.CFLoor
FROM CROOMS
GROUP BY CROOMS.RoomType, CROOMS.RoomAccess, CROOMS.CFLoor;
17
- Admin can create report to generate semesterwise classes in Carnegie
Library
SELECT CUSer.UserFirstName, CUSer.UserLastName, ClassRoom.RoomNumber, Class.Semester,
Count(Class.classID) AS CountOfclassID
FROM CUSer INNER JOIN (UserRoom INNER JOIN (Class INNER JOIN ClassRoom ON Class.classID =
ClassRoom.classID) ON UserRoom.URid = Class.URid) ON CUSer.SUID = UserRoom.SUID
GROUP BY CUSer.UserFirstName, CUSer.UserLastName, ClassRoom.RoomNumber, Class.Semester
HAVING (((Class.Semester)='Fall'));
SELECT CUSer.UserFirstName, CUSer.UserLastName, ClassRoom.RoomNumber, Class.Semester,
Count(Class.classID) AS CountOfclassID
FROM CUSer INNER JOIN (UserRoom INNER JOIN (Class INNER JOIN ClassRoom ON Class.classID =
ClassRoom.classID) ON UserRoom.URid = Class.URid) ON CUSer.SUID = UserRoom.SUID
GROUP BY CUSer.UserFirstName, CUSer.UserLastName, ClassRoom.RoomNumber, Class.Semester
HAVING (((Class.Semester)='Spring'));
18
Interfaces
Sub form with combo box
Form to fill data into Class, ClassRoom, UserRoom tables
19
Form to fill data into Crooms and Computer Lab tables
Form to fill data into User Table
20
Reports for major data questions:
- Admin can create report to generate semester wise classes in Carnegie
Library
21
-User can know how many classrooms, offices, computer lab are on each floor
22
Trigger
Before Trigger
As you can see C203 has 20 chairs and 20 tables and capacity is 20.
What my trigger does is it updates capacity = chairs + tables
create trigger updateCRooms
ON CROOMS
FOR UPDATE
AS
BEGIN
UPDATE CROOMS
SET Capacity = a.Capacity
FROM (select c.RoomNumber AS rnum,(c.no_of_tables +i.No_Of_Chairs) As 'Capacity'
FROM CROOMS c Inner join inserted i
on i.RoomNumber = c.RoomNumber
)a
where Crooms.RoomNumber = a.rnum
End;
update CROOMS
set No_Of_Chairs= 20
where RoomNumber='C203'
23
After Trigger:
You can see the capacity column of C203 has been updated

Contenu connexe

En vedette

OConnorMini-ResearchPaper
OConnorMini-ResearchPaperOConnorMini-ResearchPaper
OConnorMini-ResearchPaperMatt Thura
 
Jash mehta assignment 1Business Model
Jash mehta assignment 1Business ModelJash mehta assignment 1Business Model
Jash mehta assignment 1Business ModelJash Mehta
 
Business Data Mapping assignment 9
Business Data Mapping assignment 9Business Data Mapping assignment 9
Business Data Mapping assignment 9Jash Mehta
 
áLbum de-fotografías-audio-y-video - copia
áLbum de-fotografías-audio-y-video - copiaáLbum de-fotografías-audio-y-video - copia
áLbum de-fotografías-audio-y-video - copiaLizbeth Aleidy Zonrixss
 
บทที่ 1 เทคโนโลยีสารสนเทศและการสื่อสาร
บทที่ 1 เทคโนโลยีสารสนเทศและการสื่อสารบทที่ 1 เทคโนโลยีสารสนเทศและการสื่อสาร
บทที่ 1 เทคโนโลยีสารสนเทศและการสื่อสารKewalin Prasertdecho
 
Pawer Point de Teología " El Hijo de Dios se hace Hombre"
Pawer Point de Teología " El Hijo de Dios se hace Hombre"Pawer Point de Teología " El Hijo de Dios se hace Hombre"
Pawer Point de Teología " El Hijo de Dios se hace Hombre"Hugo Schmidt
 
Pawer de didactica
Pawer de didacticaPawer de didactica
Pawer de didacticaHugo Schmidt
 
Autoestima y rendimiento escolar.
Autoestima y rendimiento escolar.Autoestima y rendimiento escolar.
Autoestima y rendimiento escolar.Hugo Schmidt
 
Eitc team 2 tech talk-final
Eitc team 2  tech talk-finalEitc team 2  tech talk-final
Eitc team 2 tech talk-finalJash Mehta
 
Eitc team 1 of v3 annotated bibliography
Eitc team 1 of v3  annotated bibliographyEitc team 1 of v3  annotated bibliography
Eitc team 1 of v3 annotated bibliographyJash Mehta
 
Influencia de la luminosidad lunar
Influencia de la luminosidad lunarInfluencia de la luminosidad lunar
Influencia de la luminosidad lunarHugo Schmidt
 
UC and Prototyping
UC and PrototypingUC and Prototyping
UC and PrototypingJash Mehta
 
Jash mehta erd assignment
Jash mehta erd assignmentJash mehta erd assignment
Jash mehta erd assignmentJash Mehta
 

En vedette (18)

OConnorMini-ResearchPaper
OConnorMini-ResearchPaperOConnorMini-ResearchPaper
OConnorMini-ResearchPaper
 
Jash mehta assignment 1Business Model
Jash mehta assignment 1Business ModelJash mehta assignment 1Business Model
Jash mehta assignment 1Business Model
 
Business Data Mapping assignment 9
Business Data Mapping assignment 9Business Data Mapping assignment 9
Business Data Mapping assignment 9
 
áLbum de-fotografías-audio-y-video - copia
áLbum de-fotografías-audio-y-video - copiaáLbum de-fotografías-audio-y-video - copia
áLbum de-fotografías-audio-y-video - copia
 
บทที่ 1 เทคโนโลยีสารสนเทศและการสื่อสาร
บทที่ 1 เทคโนโลยีสารสนเทศและการสื่อสารบทที่ 1 เทคโนโลยีสารสนเทศและการสื่อสาร
บทที่ 1 เทคโนโลยีสารสนเทศและการสื่อสาร
 
Pawer Point de Teología " El Hijo de Dios se hace Hombre"
Pawer Point de Teología " El Hijo de Dios se hace Hombre"Pawer Point de Teología " El Hijo de Dios se hace Hombre"
Pawer Point de Teología " El Hijo de Dios se hace Hombre"
 
Ejerciciogoogledocumentovanessacastillo
EjerciciogoogledocumentovanessacastilloEjerciciogoogledocumentovanessacastillo
Ejerciciogoogledocumentovanessacastillo
 
Pawer de didactica
Pawer de didacticaPawer de didactica
Pawer de didactica
 
Autoestima y rendimiento escolar.
Autoestima y rendimiento escolar.Autoestima y rendimiento escolar.
Autoestima y rendimiento escolar.
 
Eitc team 2 tech talk-final
Eitc team 2  tech talk-finalEitc team 2  tech talk-final
Eitc team 2 tech talk-final
 
FIM_AB Burn 2015
FIM_AB Burn 2015FIM_AB Burn 2015
FIM_AB Burn 2015
 
Jof V 2016
Jof V 2016Jof V 2016
Jof V 2016
 
Eitc team 1 of v3 annotated bibliography
Eitc team 1 of v3  annotated bibliographyEitc team 1 of v3  annotated bibliography
Eitc team 1 of v3 annotated bibliography
 
MDR 2014 final
MDR 2014 finalMDR 2014 final
MDR 2014 final
 
EL UNIVERSO
EL UNIVERSOEL UNIVERSO
EL UNIVERSO
 
Influencia de la luminosidad lunar
Influencia de la luminosidad lunarInfluencia de la luminosidad lunar
Influencia de la luminosidad lunar
 
UC and Prototyping
UC and PrototypingUC and Prototyping
UC and Prototyping
 
Jash mehta erd assignment
Jash mehta erd assignmentJash mehta erd assignment
Jash mehta erd assignment
 

Similaire à Jash mehta ist 659 final project report

ADBMS ASSIGNMENT
ADBMS ASSIGNMENTADBMS ASSIGNMENT
ADBMS ASSIGNMENTLori Moore
 
2013 Collaborate - OAUG - Presentation
2013 Collaborate - OAUG - Presentation2013 Collaborate - OAUG - Presentation
2013 Collaborate - OAUG - PresentationBiju Thomas
 
MIS5101 WK10 Outcome Measures
MIS5101 WK10 Outcome MeasuresMIS5101 WK10 Outcome Measures
MIS5101 WK10 Outcome MeasuresSteven Johnson
 
Assignment # 2PreliminariesImportant Points· Evidence of acad.docx
Assignment  # 2PreliminariesImportant Points· Evidence of acad.docxAssignment  # 2PreliminariesImportant Points· Evidence of acad.docx
Assignment # 2PreliminariesImportant Points· Evidence of acad.docxjane3dyson92312
 
DB 3 Sybase ASE 15 & MS SQL Server
DB 3 Sybase ASE 15 & MS SQL Server DB 3 Sybase ASE 15 & MS SQL Server
DB 3 Sybase ASE 15 & MS SQL Server Sunny U Okoro
 
L1 Intro to Relational DBMS LP.pdfIntro to Relational .docx
L1 Intro to Relational DBMS LP.pdfIntro to Relational .docxL1 Intro to Relational DBMS LP.pdfIntro to Relational .docx
L1 Intro to Relational DBMS LP.pdfIntro to Relational .docxDIPESH30
 
Les09 (using ddl statements to create and manage tables)
Les09 (using ddl statements to create and manage tables)Les09 (using ddl statements to create and manage tables)
Les09 (using ddl statements to create and manage tables)Achmad Solichin
 
College management presentation using Oracle 10G
College management presentation using Oracle 10GCollege management presentation using Oracle 10G
College management presentation using Oracle 10GAIUB
 
It's Not You. It's Your Data Model.
It's Not You. It's Your Data Model.It's Not You. It's Your Data Model.
It's Not You. It's Your Data Model.Alex Powers
 
Dbms oracle
Dbms oracle Dbms oracle
Dbms oracle Abrar ali
 
Streaming SQL to unify batch and stream processing: Theory and practice with ...
Streaming SQL to unify batch and stream processing: Theory and practice with ...Streaming SQL to unify batch and stream processing: Theory and practice with ...
Streaming SQL to unify batch and stream processing: Theory and practice with ...Fabian Hueske
 
Performance Tuning With Oracle ASH and AWR. Part 1 How And What
Performance Tuning With Oracle ASH and AWR. Part 1 How And WhatPerformance Tuning With Oracle ASH and AWR. Part 1 How And What
Performance Tuning With Oracle ASH and AWR. Part 1 How And Whatudaymoogala
 
The ultimate-guide-to-sql
The ultimate-guide-to-sqlThe ultimate-guide-to-sql
The ultimate-guide-to-sqlMcNamaraChiwaye
 
Advanced tips for making Oracle databases faster
Advanced tips for making Oracle databases fasterAdvanced tips for making Oracle databases faster
Advanced tips for making Oracle databases fasterSolarWinds
 
Advanced plsql mock_assessment
Advanced plsql mock_assessmentAdvanced plsql mock_assessment
Advanced plsql mock_assessmentSaurabh K. Gupta
 

Similaire à Jash mehta ist 659 final project report (20)

Sq lite module6
Sq lite module6Sq lite module6
Sq lite module6
 
ADBMS ASSIGNMENT
ADBMS ASSIGNMENTADBMS ASSIGNMENT
ADBMS ASSIGNMENT
 
2013 Collaborate - OAUG - Presentation
2013 Collaborate - OAUG - Presentation2013 Collaborate - OAUG - Presentation
2013 Collaborate - OAUG - Presentation
 
Less08 Schema
Less08 SchemaLess08 Schema
Less08 Schema
 
MIS5101 WK10 Outcome Measures
MIS5101 WK10 Outcome MeasuresMIS5101 WK10 Outcome Measures
MIS5101 WK10 Outcome Measures
 
Assignment # 2PreliminariesImportant Points· Evidence of acad.docx
Assignment  # 2PreliminariesImportant Points· Evidence of acad.docxAssignment  # 2PreliminariesImportant Points· Evidence of acad.docx
Assignment # 2PreliminariesImportant Points· Evidence of acad.docx
 
DB 3 Sybase ASE 15 & MS SQL Server
DB 3 Sybase ASE 15 & MS SQL Server DB 3 Sybase ASE 15 & MS SQL Server
DB 3 Sybase ASE 15 & MS SQL Server
 
L1 Intro to Relational DBMS LP.pdfIntro to Relational .docx
L1 Intro to Relational DBMS LP.pdfIntro to Relational .docxL1 Intro to Relational DBMS LP.pdfIntro to Relational .docx
L1 Intro to Relational DBMS LP.pdfIntro to Relational .docx
 
Les09 (using ddl statements to create and manage tables)
Les09 (using ddl statements to create and manage tables)Les09 (using ddl statements to create and manage tables)
Les09 (using ddl statements to create and manage tables)
 
College management presentation using Oracle 10G
College management presentation using Oracle 10GCollege management presentation using Oracle 10G
College management presentation using Oracle 10G
 
It's Not You. It's Your Data Model.
It's Not You. It's Your Data Model.It's Not You. It's Your Data Model.
It's Not You. It's Your Data Model.
 
Les09
Les09Les09
Les09
 
Dbms oracle
Dbms oracle Dbms oracle
Dbms oracle
 
plsql Les09
 plsql Les09 plsql Les09
plsql Les09
 
Streaming SQL to unify batch and stream processing: Theory and practice with ...
Streaming SQL to unify batch and stream processing: Theory and practice with ...Streaming SQL to unify batch and stream processing: Theory and practice with ...
Streaming SQL to unify batch and stream processing: Theory and practice with ...
 
Performance Tuning With Oracle ASH and AWR. Part 1 How And What
Performance Tuning With Oracle ASH and AWR. Part 1 How And WhatPerformance Tuning With Oracle ASH and AWR. Part 1 How And What
Performance Tuning With Oracle ASH and AWR. Part 1 How And What
 
The ultimate-guide-to-sql
The ultimate-guide-to-sqlThe ultimate-guide-to-sql
The ultimate-guide-to-sql
 
Advanced tips for making Oracle databases faster
Advanced tips for making Oracle databases fasterAdvanced tips for making Oracle databases faster
Advanced tips for making Oracle databases faster
 
Advanced plsql mock_assessment
Advanced plsql mock_assessmentAdvanced plsql mock_assessment
Advanced plsql mock_assessment
 
SQL Reports in Koha
SQL Reports in KohaSQL Reports in Koha
SQL Reports in Koha
 

Dernier

VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130Suhani Kapoor
 
Schema on read is obsolete. Welcome metaprogramming..pdf
Schema on read is obsolete. Welcome metaprogramming..pdfSchema on read is obsolete. Welcome metaprogramming..pdf
Schema on read is obsolete. Welcome metaprogramming..pdfLars Albertsson
 
定制英国白金汉大学毕业证(UCB毕业证书) 成绩单原版一比一
定制英国白金汉大学毕业证(UCB毕业证书)																			成绩单原版一比一定制英国白金汉大学毕业证(UCB毕业证书)																			成绩单原版一比一
定制英国白金汉大学毕业证(UCB毕业证书) 成绩单原版一比一ffjhghh
 
Smarteg dropshipping via API with DroFx.pptx
Smarteg dropshipping via API with DroFx.pptxSmarteg dropshipping via API with DroFx.pptx
Smarteg dropshipping via API with DroFx.pptxolyaivanovalion
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
代办国外大学文凭《原版美国UCLA文凭证书》加州大学洛杉矶分校毕业证制作成绩单修改
代办国外大学文凭《原版美国UCLA文凭证书》加州大学洛杉矶分校毕业证制作成绩单修改代办国外大学文凭《原版美国UCLA文凭证书》加州大学洛杉矶分校毕业证制作成绩单修改
代办国外大学文凭《原版美国UCLA文凭证书》加州大学洛杉矶分校毕业证制作成绩单修改atducpo
 
Low Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service Bhilai
Low Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service BhilaiLow Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service Bhilai
Low Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service BhilaiSuhani Kapoor
 
April 2024 - Crypto Market Report's Analysis
April 2024 - Crypto Market Report's AnalysisApril 2024 - Crypto Market Report's Analysis
April 2024 - Crypto Market Report's Analysismanisha194592
 
VidaXL dropshipping via API with DroFx.pptx
VidaXL dropshipping via API with DroFx.pptxVidaXL dropshipping via API with DroFx.pptx
VidaXL dropshipping via API with DroFx.pptxolyaivanovalion
 
Midocean dropshipping via API with DroFx
Midocean dropshipping via API with DroFxMidocean dropshipping via API with DroFx
Midocean dropshipping via API with DroFxolyaivanovalion
 
BigBuy dropshipping via API with DroFx.pptx
BigBuy dropshipping via API with DroFx.pptxBigBuy dropshipping via API with DroFx.pptx
BigBuy dropshipping via API with DroFx.pptxolyaivanovalion
 
Call Girls in Sarai Kale Khan Delhi 💯 Call Us 🔝9205541914 🔝( Delhi) Escorts S...
Call Girls in Sarai Kale Khan Delhi 💯 Call Us 🔝9205541914 🔝( Delhi) Escorts S...Call Girls in Sarai Kale Khan Delhi 💯 Call Us 🔝9205541914 🔝( Delhi) Escorts S...
Call Girls in Sarai Kale Khan Delhi 💯 Call Us 🔝9205541914 🔝( Delhi) Escorts S...Delhi Call girls
 
Market Analysis in the 5 Largest Economic Countries in Southeast Asia.pdf
Market Analysis in the 5 Largest Economic Countries in Southeast Asia.pdfMarket Analysis in the 5 Largest Economic Countries in Southeast Asia.pdf
Market Analysis in the 5 Largest Economic Countries in Southeast Asia.pdfRachmat Ramadhan H
 
FESE Capital Markets Fact Sheet 2024 Q1.pdf
FESE Capital Markets Fact Sheet 2024 Q1.pdfFESE Capital Markets Fact Sheet 2024 Q1.pdf
FESE Capital Markets Fact Sheet 2024 Q1.pdfMarinCaroMartnezBerg
 
꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Call
꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Call꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Call
꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Callshivangimorya083
 
Week-01-2.ppt BBB human Computer interaction
Week-01-2.ppt BBB human Computer interactionWeek-01-2.ppt BBB human Computer interaction
Week-01-2.ppt BBB human Computer interactionfulawalesam
 
B2 Creative Industry Response Evaluation.docx
B2 Creative Industry Response Evaluation.docxB2 Creative Industry Response Evaluation.docx
B2 Creative Industry Response Evaluation.docxStephen266013
 

Dernier (20)

VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
 
Schema on read is obsolete. Welcome metaprogramming..pdf
Schema on read is obsolete. Welcome metaprogramming..pdfSchema on read is obsolete. Welcome metaprogramming..pdf
Schema on read is obsolete. Welcome metaprogramming..pdf
 
Delhi 99530 vip 56974 Genuine Escort Service Call Girls in Kishangarh
Delhi 99530 vip 56974 Genuine Escort Service Call Girls in  KishangarhDelhi 99530 vip 56974 Genuine Escort Service Call Girls in  Kishangarh
Delhi 99530 vip 56974 Genuine Escort Service Call Girls in Kishangarh
 
定制英国白金汉大学毕业证(UCB毕业证书) 成绩单原版一比一
定制英国白金汉大学毕业证(UCB毕业证书)																			成绩单原版一比一定制英国白金汉大学毕业证(UCB毕业证书)																			成绩单原版一比一
定制英国白金汉大学毕业证(UCB毕业证书) 成绩单原版一比一
 
Smarteg dropshipping via API with DroFx.pptx
Smarteg dropshipping via API with DroFx.pptxSmarteg dropshipping via API with DroFx.pptx
Smarteg dropshipping via API with DroFx.pptx
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
代办国外大学文凭《原版美国UCLA文凭证书》加州大学洛杉矶分校毕业证制作成绩单修改
代办国外大学文凭《原版美国UCLA文凭证书》加州大学洛杉矶分校毕业证制作成绩单修改代办国外大学文凭《原版美国UCLA文凭证书》加州大学洛杉矶分校毕业证制作成绩单修改
代办国外大学文凭《原版美国UCLA文凭证书》加州大学洛杉矶分校毕业证制作成绩单修改
 
Sampling (random) method and Non random.ppt
Sampling (random) method and Non random.pptSampling (random) method and Non random.ppt
Sampling (random) method and Non random.ppt
 
Low Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service Bhilai
Low Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service BhilaiLow Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service Bhilai
Low Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service Bhilai
 
April 2024 - Crypto Market Report's Analysis
April 2024 - Crypto Market Report's AnalysisApril 2024 - Crypto Market Report's Analysis
April 2024 - Crypto Market Report's Analysis
 
VidaXL dropshipping via API with DroFx.pptx
VidaXL dropshipping via API with DroFx.pptxVidaXL dropshipping via API with DroFx.pptx
VidaXL dropshipping via API with DroFx.pptx
 
Midocean dropshipping via API with DroFx
Midocean dropshipping via API with DroFxMidocean dropshipping via API with DroFx
Midocean dropshipping via API with DroFx
 
BigBuy dropshipping via API with DroFx.pptx
BigBuy dropshipping via API with DroFx.pptxBigBuy dropshipping via API with DroFx.pptx
BigBuy dropshipping via API with DroFx.pptx
 
Call Girls in Sarai Kale Khan Delhi 💯 Call Us 🔝9205541914 🔝( Delhi) Escorts S...
Call Girls in Sarai Kale Khan Delhi 💯 Call Us 🔝9205541914 🔝( Delhi) Escorts S...Call Girls in Sarai Kale Khan Delhi 💯 Call Us 🔝9205541914 🔝( Delhi) Escorts S...
Call Girls in Sarai Kale Khan Delhi 💯 Call Us 🔝9205541914 🔝( Delhi) Escorts S...
 
Market Analysis in the 5 Largest Economic Countries in Southeast Asia.pdf
Market Analysis in the 5 Largest Economic Countries in Southeast Asia.pdfMarket Analysis in the 5 Largest Economic Countries in Southeast Asia.pdf
Market Analysis in the 5 Largest Economic Countries in Southeast Asia.pdf
 
FESE Capital Markets Fact Sheet 2024 Q1.pdf
FESE Capital Markets Fact Sheet 2024 Q1.pdfFESE Capital Markets Fact Sheet 2024 Q1.pdf
FESE Capital Markets Fact Sheet 2024 Q1.pdf
 
꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Call
꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Call꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Call
꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Call
 
꧁❤ Aerocity Call Girls Service Aerocity Delhi ❤꧂ 9999965857 ☎️ Hard And Sexy ...
꧁❤ Aerocity Call Girls Service Aerocity Delhi ❤꧂ 9999965857 ☎️ Hard And Sexy ...꧁❤ Aerocity Call Girls Service Aerocity Delhi ❤꧂ 9999965857 ☎️ Hard And Sexy ...
꧁❤ Aerocity Call Girls Service Aerocity Delhi ❤꧂ 9999965857 ☎️ Hard And Sexy ...
 
Week-01-2.ppt BBB human Computer interaction
Week-01-2.ppt BBB human Computer interactionWeek-01-2.ppt BBB human Computer interaction
Week-01-2.ppt BBB human Computer interaction
 
B2 Creative Industry Response Evaluation.docx
B2 Creative Industry Response Evaluation.docxB2 Creative Industry Response Evaluation.docx
B2 Creative Industry Response Evaluation.docx
 

Jash mehta ist 659 final project report

  • 1. 1 INDOOR MAP PROJECT (ROOMS): CARNEGIE LIBRARY JASH MEHTA IST 659 FINAL PROJECT REPORT
  • 2. 2 Table of Contents Project Summary ……………………………………………………..3 Tables and Attributes ……………………………………………………..5 Entity Relationship Diagram ……………………………………………………..7 Business Rules …………………………………………………….10 Database Infrastructure …………………………………………………….10 SQL Scripts for Creating and Inserting Sample Data …………………………………………………….10 Major Data Questions …………………………………………………….16 Forms and Reports(Interfaces) …………………………………………………….18 Triggers …………………………………………………….22
  • 3. 3 Summary: The resources of the Carnegie include rooms that a SU user could use at the library. For instance, there are rooms like Offices, Stack Area, Classrooms, Computer Lab, Computer Cluster. All rooms have resources such as chairs & table and technology. Classrooms can be booked by faculty. Therefore if faculty wants to know which rooms has sufficient capacity then the faculty can log into the app to find out about the room he/she wants to book. The resources can be located in a room or outside a room. These resources are classified based on resource types and also based on the different levels they are located on. Supposedly, other resources include dust bins, elevators, exits and entrances in the Carnegie Library. User (student or faculty) can log into the SU Indoor Map to find out these other resources. The scope of my project is limited to identify the rooms and other resources and their locations at Carnegie so that these details can be fetched by the SU Indoor Outdoor app. Major Data Question The App will be used by two kind of users  SU students and faculty  Database administrator Why would SU students and faculty query the database? Faculty has the privilege to book rooms in Carnegie Library therefore if any professor would like to know information regarding the rooms then the database would be queried
  • 4. 4 Students would like to locate the rooms and respective events in the room. Also, students & faculty would like to locate the other resources such as drinking fountain, washrooms, entrance, exits and elevators. Why would database administrator query the database? The database administrator would query the database in the event of finding out the current status of any room or event. Administrator would like to query in order to update the database. For example, if the semester changes and the events in the room needs to be changed then it responsibility of the administrator to change it. Also, if there is any reconstruction or reordering of any of the rooms then the administrator must make changes in the database.
  • 5. 5 Tables & Attributes Database object & Attributes Description User User of the SU indoor Map PK SUID UserFirstName UserLastName Age Email Gender UserType Primary Key: Identifies the user uniquely User’s First Name User’s Last Name Age of the user SuEmail of the user Gender of the user Faculty or Student Rooms Stores Information about all the rooms PK RoomNumber Department Floor RoomType Timings No_Of_Projectors No_Of_Screens NoOfChairs NoOfTables RoomAccess Room Type PK: Identifies the room uniquely Under which department does the room come On which floor is the room located Office, Classroom, Computer Lab etc Opening and Closing Hours Number of resources in the rooms: Number of projectors, screens, chairs and tables Private or Public Discriminator: Classroom(CR), ComputerLab(CL), Office (O) Other Resources Stores other resources such as washrooms, bins, drinking fountain, elevators, entrance and exits PK ResourceID FK SUID ResourceName Floor Unique ID for resources to identify resources SUID taken as foreign key from the User Table Vending Machine, Washroom, Dustbin Floor on which the resource is located UserRoom Bridge table between user and Rooms as it is many to many relationship between user and rooms
  • 6. 6 PK URid FK SUID FK RoomNumber Start Time End Time Date Uniquely identifies the booking for the user and room Foreign key from user table Foreign key from Rooms table Start time the room booked End time of the room booked The date for which room is booked Computer Lab Stores Information about all the computers in the room PK,FK RoomNumber NoOfComputers NameOfPrinter TypeOfPrinter NameOfScanner TypeOfScanner Primary key as well as foreign key to implement disjoint logic Number of Computers Name of the printer Brand/Company of the printer Name of the Scanner Brand/Company of the scanner Classroom Stores information regarding the classrooms PK, FK RoomNumber FK ClassID Primary key as well as foreign key to implement disjoint logic Class Stores information regarding the event occurring in the classroom PK ClassID URid School Year Semester Uniquely identifies the class which is being conducted in the classroom URid as foreign key from UserRoom bridge table The school year: For example 2016, 2017 Fall, Spring, Summer Office Stores information regarding the person and the contact in the office PK, FK RoomNumber PersonIncharge_FirstName PersonIncharge_LastName ContactNumber Primary key as well as foreign key to implement disjoint logic First Name of the person Last Name of the person Phone number of the office
  • 10. 10 Business Rules  Many users can use/search for many rooms  A user of the App may search for one or many other resources  The rooms are complete disjoint entities. A room can be a computer lab, computer cluster, classroom, office or a stack area  One classroom can have one class at a given time Database Infrastructure: The database infrastructure is based on client-server model. SQL server is used as the database engine and access is used as the interface design tool. Data is inserted, deleted, updated and queried from the SQL server database with the help of forms on Access. Useful data stored on SQL database can also be viewed with the help of reports generated through access. SQL Scripts for Creating and Inserting Sample Data: NOTE: I am giving only one insert script for each table rest of the data was inserted by access forms CREATE TABLE CUSer ( SUID CHAR(10)NOT NULL, UserFirstName Varchar(30), UserLastName Varchar(30), UserAge INTEGER , UserEmail varchar(20), UserGender Varchar(2), User_Type Varchar(30), CONSTRAINT SUID_PK PRIMARY KEY (SUID) ); INSERT INTO CUSer Values ('12345678','Sachin','Tendulkar','44','saten@syr.edu','M','Faculty')
  • 11. 11 CREATE TABLE CROOMS ( RoomNumber Char(5) NOT NULL, Department varchar(30), CFLoor char(2) , Timings varchar(20) , No_Of_Projectors INTEGER, No_Of_Screens INTEGER, No_Of_Chairs INTEGER, No_Of_Tables INTEGER, Capacity INTEGER, RoomAccess Varchar(30), RoomType Varchar(30) NOT NULL CHECK (RoomType In ('CL','CR','O')), CONSTRAINT RoomNumber_PK PRIMARY KEY (RoomNumber) ); INSERT INTO CROOMS Values ('C108','ABC','2','8 am - 5pm',1,1,20,3,23,'public','CR') CREATE TABLE Resources ( ResourceID Varchar(30) NOT NULL,
  • 12. 12 SUID CHAR(10) NOT NULL, ResourceName Varchar(30), CFLoor char(2), CONSTRAINT ResourceID_PK PRIMARY KEY (ResourceID), CONSTRAINT Resources_FK_SUID FOREIGN KEY (SUID) References CUSer(SUID) ); INSERT INTO Resources Values ('VM103','12345678','Vending Machine','1') CREATE TABLE UserRoom ( URid Varchar(15) NOT NULL, SUID CHAR(10) NOT NULL, RoomNumber Char(5) NOT NULL, URSTime Varchar(30), URETime Varchar (30), URDATE Varchar (30), CONSTRAINT URid_PK PRIMARY KEY (URid), CONSTRAINT UserRoom_FK_SUID FOREIGN KEY (SUID) References CUser(SUID), CONSTRAINT UserRoom_FK_RoomNumber FOREIGN KEY (RoomNumber) References CROOMS(RoomNumber) ); INSERT INTO UserRoom Values ('15','10001','c201','8 am', '9 am', 'May')
  • 13. 13 Create table Class ( classID Varchar(30) NOT NULL, URid Varchar(15) NOT NULL, SchoolYear Varchar(30), Semester Varchar(30), CONSTRAINT Class_PK PRIMARY KEY (classID), CONSTRAINT Class_FK_URid FOREIGN KEY (URid) References UserRoom(URid) ); INSERT INTO Class Values ('c15','15','2016','Spring') CREATE TABLE ClassRoom ( RoomNumber Char(5)NOT NULL, classID Varchar(30) NOT NULL,
  • 14. 14 CONSTRAINT RoomNumber_PK2 PRIMARY KEY (RoomNumber), CONSTRAINT ClassRoom_FK_RoomNumber FOREIGN KEY (RoomNumber) References CROOMS(RoomNumber), CONSTRAINT ClassRoom_FK_classID FOREIGN KEY (classID) References Class(classID), ); INSERT INTO ClassRoom Values ('c201','c15') CREATE TABLE Office ( RoomNumber Char(5)NOT NULL, PersonInCharge_FNAME Varchar(30) , PersonInCharge_LNAME Varchar(30) , PhoneNumber Varchar(30), CONSTRAINT RoomNumber_PK3 PRIMARY KEY (RoomNumber), CONSTRAINT Office_FK_RoomNumber FOREIGN KEY (RoomNumber) References CROOMS(RoomNumber), );
  • 15. 15 CREATE TABLE ComputerLab ( RoomNumber Char(5) NOT NULL, No_Of_Computer INTEGER, No_Of_Printer INTEGER, Name_Of_Printer varchar(30), No_Of_scanner INTEGER, Name_of_scanner varchar(30), CONSTRAINT RoomNumber_PK1 PRIMARY KEY (RoomNumber), CONSTRAINT ComputerLab_FK_RoomNumber FOREIGN KEY (RoomNumber) References CROOMS(RoomNumber) ); INSERT INTO ComputerLab Values ('Cl102',45,2,'HP Laser Jet', 45, 'Hp')
  • 16. 16 Major Data Questions -User can know how many classrooms, offices, computer lab are on each floor SELECT Count(CROOMS.RoomNumber) AS CountOfRoomNumber, CROOMS.RoomType, CROOMS.RoomAccess, CROOMS.CFLoor FROM CROOMS GROUP BY CROOMS.RoomType, CROOMS.RoomAccess, CROOMS.CFLoor;
  • 17. 17 - Admin can create report to generate semesterwise classes in Carnegie Library SELECT CUSer.UserFirstName, CUSer.UserLastName, ClassRoom.RoomNumber, Class.Semester, Count(Class.classID) AS CountOfclassID FROM CUSer INNER JOIN (UserRoom INNER JOIN (Class INNER JOIN ClassRoom ON Class.classID = ClassRoom.classID) ON UserRoom.URid = Class.URid) ON CUSer.SUID = UserRoom.SUID GROUP BY CUSer.UserFirstName, CUSer.UserLastName, ClassRoom.RoomNumber, Class.Semester HAVING (((Class.Semester)='Fall')); SELECT CUSer.UserFirstName, CUSer.UserLastName, ClassRoom.RoomNumber, Class.Semester, Count(Class.classID) AS CountOfclassID FROM CUSer INNER JOIN (UserRoom INNER JOIN (Class INNER JOIN ClassRoom ON Class.classID = ClassRoom.classID) ON UserRoom.URid = Class.URid) ON CUSer.SUID = UserRoom.SUID GROUP BY CUSer.UserFirstName, CUSer.UserLastName, ClassRoom.RoomNumber, Class.Semester HAVING (((Class.Semester)='Spring'));
  • 18. 18 Interfaces Sub form with combo box Form to fill data into Class, ClassRoom, UserRoom tables
  • 19. 19 Form to fill data into Crooms and Computer Lab tables Form to fill data into User Table
  • 20. 20 Reports for major data questions: - Admin can create report to generate semester wise classes in Carnegie Library
  • 21. 21 -User can know how many classrooms, offices, computer lab are on each floor
  • 22. 22 Trigger Before Trigger As you can see C203 has 20 chairs and 20 tables and capacity is 20. What my trigger does is it updates capacity = chairs + tables create trigger updateCRooms ON CROOMS FOR UPDATE AS BEGIN UPDATE CROOMS SET Capacity = a.Capacity FROM (select c.RoomNumber AS rnum,(c.no_of_tables +i.No_Of_Chairs) As 'Capacity' FROM CROOMS c Inner join inserted i on i.RoomNumber = c.RoomNumber )a where Crooms.RoomNumber = a.rnum End; update CROOMS set No_Of_Chairs= 20 where RoomNumber='C203'
  • 23. 23 After Trigger: You can see the capacity column of C203 has been updated