text: -- MySQL dump 10.13  Distrib 8.0.17, for macos10.14 (x86_64)
  --
  -- Host: localhost    Database: hospital
  -- ------------------------------------------------------
  -- Server version	8.0.15
  
  /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
  /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
  /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
  /*!50503 SET NAMES utf8 */;
  /*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
  /*!40103 SET TIME_ZONE='+00:00' */;
  /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
  /*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
  /*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
  /*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
  
  --
  -- Table structure for table `admin`
  --
  
  DROP TABLE IF EXISTS `admin`;
  /*!40101 SET @saved_cs_client     = @@character_set_client */;
  /*!50503 SET character_set_client = utf8mb4 */;
  CREATE TABLE `admin` (
    `firstName` varchar(45) NOT NULL,
    `lastName` varchar(45) NOT NULL,
    `username` varchar(45) NOT NULL,
    `password` varchar(45) NOT NULL,
    `email` varchar(45) NOT NULL,
    `contact` varchar(45) NOT NULL,
    PRIMARY KEY (`username`),
    UNIQUE KEY `username_UNIQUE` (`username`)
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
  /*!40101 SET character_set_client = @saved_cs_client */;
  
  --
  -- Dumping data for table `admin`
  --
  
  LOCK TABLES `admin` WRITE;
  /*!40000 ALTER TABLE `admin` DISABLE KEYS */;
  INSERT INTO `admin` VALUES ('Dan','Brown','dan','dan','dan2gmail.com','042323229');
  /*!40000 ALTER TABLE `admin` ENABLE KEYS */;
  UNLOCK TABLES;
  
  --
  -- Table structure for table `appointment`
  --
  
  DROP TABLE IF EXISTS `appointment`;
  /*!40101 SET @saved_cs_client     = @@character_set_client */;
  /*!50503 SET character_set_client = utf8mb4 */;
  CREATE TABLE `appointment` (
    `pId` varchar(45) NOT NULL,
    `dId` varchar(45) NOT NULL,
    `appDate` date NOT NULL,
    `appTime` time NOT NULL,
    PRIMARY KEY (`appDate`,`pId`),
    KEY `pId_idx` (`pId`),
    KEY `dId_idx` (`dId`),
    CONSTRAINT `dId` FOREIGN KEY (`dId`) REFERENCES `doctor` (`dId`),
    CONSTRAINT `pId` FOREIGN KEY (`pId`) REFERENCES `patient` (`pId`)
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
  /*!40101 SET character_set_client = @saved_cs_client */;
  
  --
  -- Dumping data for table `appointment`
  --
  
  LOCK TABLES `appointment` WRITE;
  /*!40000 ALTER TABLE `appointment` DISABLE KEYS */;
  INSERT INTO `appointment` VALUES ('p1','d1','2020-05-05','10:00:00');
  /*!40000 ALTER TABLE `appointment` ENABLE KEYS */;
  UNLOCK TABLES;
  
  --
  -- Table structure for table `doctor`
  --
  
  DROP TABLE IF EXISTS `doctor`;
  /*!40101 SET @saved_cs_client     = @@character_set_client */;
  /*!50503 SET character_set_client = utf8mb4 */;
  CREATE TABLE `doctor` (
    `dId` varchar(45) NOT NULL,
    `dFirstnName` varchar(45) NOT NULL,
    `dLastName` varchar(45) NOT NULL,
    `username` varchar(45) NOT NULL,
    `password` varchar(45) NOT NULL,
    `email` varchar(45) DEFAULT NULL,
    `contact` varchar(45) NOT NULL,
    `address` varchar(45) DEFAULT NULL,
    `gender` enum('m','f') NOT NULL,
    PRIMARY KEY (`dId`,`dFirstnName`),
    UNIQUE KEY `username_UNIQUE` (`username`)
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
  /*!40101 SET character_set_client = @saved_cs_client */;
  
  --
  -- Dumping data for table `doctor`
  --
  
  LOCK TABLES `doctor` WRITE;
  /*!40000 ALTER TABLE `doctor` DISABLE KEYS */;
  INSERT INTO `doctor` VALUES ('d1','Chris','Mathew','mathew','mathew','mathew@gmail.com','0423232229','11 reversby','m'),('d2','Santiago','Victoria','victoria','victoria','victoria@gmail.com','043434228',NULL,'m');
  /*!40000 ALTER TABLE `doctor` ENABLE KEYS */;
  UNLOCK TABLES;
  
  --
  -- Table structure for table `patient`
  --
  
  DROP TABLE IF EXISTS `patient`;
  /*!40101 SET @saved_cs_client     = @@character_set_client */;
  /*!50503 SET character_set_client = utf8mb4 */;
  CREATE TABLE `patient` (
    `pId` varchar(45) NOT NULL,
    `pFirstName` varchar(45) NOT NULL,
    `pLastName` varchar(45) NOT NULL,
    `dob` date NOT NULL,
    `gender` enum('m','f') NOT NULL,
    `email` varchar(45) DEFAULT NULL,
    `contact` varchar(45) NOT NULL,
    `address` tinytext,
    `complaint` text,
    `healthConditions` text,
    `allergies` tinytext,
    PRIMARY KEY (`pId`,`pFirstName`,`pLastName`,`dob`),
    UNIQUE KEY `pId_UNIQUE` (`pId`)
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
  /*!40101 SET character_set_client = @saved_cs_client */;
  
  --
  -- Dumping data for table `patient`
  --
  
  LOCK TABLES `patient` WRITE;
  /*!40000 ALTER TABLE `patient` DISABLE KEYS */;
  INSERT INTO `patient` VALUES ('p1','Williams','David','1994-12-25','m','david@gmail.com','0474747447','2a church street paramatta','cough and cold',NULL,'shrimp'),('p2','Dom','Chris','1980-12-25','m','chris@gmail.com','0446464664',NULL,'sprain','blood pressure',NULL),('p3','Stark','Rob','1990-12-25','m',NULL,'0474747447','11/2 bellavista','hairfall',NULL,NULL);
  /*!40000 ALTER TABLE `patient` ENABLE KEYS */;
  UNLOCK TABLES;
  
  --
  -- Table structure for table `receptionStaff`
  --
  
  DROP TABLE IF EXISTS `receptionStaff`;
  /*!40101 SET @saved_cs_client     = @@character_set_client */;
  /*!50503 SET character_set_client = utf8mb4 */;
  CREATE TABLE `receptionStaff` (
    `rId` varchar(45) NOT NULL,
    `rFirstName` varchar(45) NOT NULL,
    `rLastNmae` varchar(45) NOT NULL,
    `username` varchar(45) NOT NULL,
    `password` varchar(45) NOT NULL,
    `email` varchar(45) DEFAULT NULL,
    `contact` varchar(45) NOT NULL,
    `address` varchar(45) DEFAULT NULL,
    `gender` enum('m','f') NOT NULL,
    PRIMARY KEY (`rId`),
    UNIQUE KEY `username_UNIQUE` (`username`)
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
  /*!40101 SET character_set_client = @saved_cs_client */;
  
  --
  -- Dumping data for table `receptionStaff`
  --
  
  LOCK TABLES `receptionStaff` WRITE;
  /*!40000 ALTER TABLE `receptionStaff` DISABLE KEYS */;
  INSERT INTO `receptionStaff` VALUES ('r1','Susane','William','susane','susane','susane@gmail.com','046565665',NULL,'m');
  /*!40000 ALTER TABLE `receptionStaff` ENABLE KEYS */;
  UNLOCK TABLES;
  /*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
  
  /*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
  /*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
  /*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
  /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
  /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
  /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
  /*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
  
  -- Dump completed on 2020-05-03 14:01:29
  