Skip to content

PetePrattis/hospital-database-with-JDBC-client

Repository files navigation

A JDBC client Program / Project

This is a jdbc client project from my early days as a Computer Science student

This programm was created for the fourth semester class Data Bases and is the final project for the class

Description of project

A jdbc application that runs queries in pgAdmin to simulate the functionality of a hospital's database.

Functionality of project

  1. The database saves information about the hospital's doctors of a variety of departments
  2. The database saves doctors' information are (name, surname, specialty, contact information, department code, etc.)
  3. The database saves the hospital's patients and their information (name, surname, contact information, etc.)
  4. The database saves the appointments and the diagnosis for each patient and information and date about them
  5. The database saves each patient's medical record, including treatments and prescription drugs
  6. There is a predetermined dataset used for this project

Impementation of project

  1. Design the relational scheme of the database and implement the creation queries in the PostgreSQL DMBS
  2. Apply the normalization theory to the relational scheme of the DB to check if it follows 3NF or BCNF
  3. Insert the data from the given dataset using proper queries
  4. Implement some functionality using proper queries:

a. What are the drugs (maximum and minimum number) prescribed
b. What are the diagnoses of the last week
c. What are the doctor's 'X' appointments last month
d. Who are the patients who have seen more than one doctor
e. From what department have most patients been examined
f. What is the average number of patients examined per department

  1. Implement some functionality using triggers:

a. Creation of trigger and function that will execute for every patent examined and diagnosis to update patient's medical file
b. Creation of trigger and function that implement's the query d)

  1. Connect databse with JDBC client in Java using the proper library
  2. Write a Java console application that will execute the queries

About this project

  • There is a predetermined dataset used for this project
  • The comments to make the code understandable, are within the archives
  • This project was written in Eclipse Java IDE
  • This repository was created to show the variety of the work I did and experience I gained as a student