When I was in this class, I was working for a convalescent home therefore myself and three other students did our semester project on a chain of convalescent centers. We implemented a database in SQL and then used eclipse to establish a connection to the database in java.
Here's the link to the sql code: Chaindb.sql
UML Diagram: UML
Type of Database: Chain of convalescent centers
Purpose of database: To manage convalescent centers and their employees.
User of database: CEO, administrators
Information to store:
Person(fName,lName,streetNo,pID)
*The Person class provides a general description of a person. No Person can be uniquely identified, because every single Person in the database should either be an Employee or a Patient. fName is the first name, lName is the last name, and streetNo is the street number of the person.
Employee(phone, hiringDate, rank, payscale,eID)
*The Employee class is a specialization of the Person class and describes an employee. Like the Person class, Employee is too general for us to uniquely identify any one Employee. eID is a surrogate key derived from the pID.
Department(type,budget,streetNo)
*The Department class describes a department in the corporate offices. There are several departments, most of which employ a number of employees, but some of which are new and thus have no employees yet. StreetNo uniquely identifies departments, and type and budget may differ or be the same among different departments. Type is the type of corporate office, budget is said department’s budget, and streetNo is the street number of said department.
CorporateEmployee(benefits)
*The CorporateEmployee class describes a specialization of the Employee class. Infinitely many CorporateEmployees may be uniquely identified by their pID. benefits describes said benefits awarded to the corporate employee.
Center(zipcode, phone, currentAdministrator, chainNo,streetNo,noPatients)
*The Center class describes the different convalescent centers within the database. A Center is uniquely identified by its chainNo, and infinitely many centers may exist. zipcode gives the zip-code, phone gives the phone number, currentAdministrater names the current administrater, chainNo gives the unique number that describes the center and streetNo is the number of the street in which the center is located. The number of patients under the center’s care is modeled by noPatients.
Patient(roomNo, diagnosis, insuranceType,emergencyContact)
*The Patient class is a specialization of the Person class. There may be infinitely many patients uniquely identified within the database. roomNo describes the room in which the patient is being cared for, diagnosis describes the diagnosis given to the patient, insuranceType describes the type of insurance under which the patient is covered, and emergencyContact is the phone number of the emergency contact for the patient.
MedicalStaff(role,abbrev,title,licenseNo,station)
*MedicalStaff is a specialization of the Employee class. role describes the staff’s job in the center, abbrev describes the abbreviation attached to the staff member. Title is the medical staff’s title, licenseNo is the number of the staff’s license, and station is where the staff is the station in which the staff is stationed.


No comments:
Post a Comment