text: -- MySQL dump 10.13  Distrib 8.0.23, for Win64 (x86_64)
  --
  -- Host: sunnywalk.ciz7r2rp57oo.eu-west-2.rds.amazonaws.com    Database: sunnywalk
  -- ------------------------------------------------------
  -- Server version	8.0.23
  
  /*!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 */;
  SET @MYSQLDUMP_TEMP_LOG_BIN = @@SESSION.SQL_LOG_BIN;
  SET @@SESSION.SQL_LOG_BIN= 0;
  
  --
  -- GTID state at the beginning of the backup 
  --
  
  SET @@GLOBAL.GTID_PURGED=/*!80000 '+'*/ '';
  
  --
  -- Table structure for table `api_key`
  --
  
  DROP TABLE IF EXISTS `api_key`;
  /*!40101 SET @saved_cs_client     = @@character_set_client */;
  /*!50503 SET character_set_client = utf8mb4 */;
  CREATE TABLE `api_key` (
    `api_service` varchar(255) NOT NULL,
    `api_key` varchar(255) DEFAULT NULL,
    PRIMARY KEY (`api_service`)
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
  /*!40101 SET character_set_client = @saved_cs_client */;
  
  --
  -- Table structure for table `hibernate_sequence`
  --
  
  DROP TABLE IF EXISTS `hibernate_sequence`;
  /*!40101 SET @saved_cs_client     = @@character_set_client */;
  /*!50503 SET character_set_client = utf8mb4 */;
  CREATE TABLE `hibernate_sequence` (
    `next_val` bigint DEFAULT NULL
  ) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
  /*!40101 SET character_set_client = @saved_cs_client */;
  
  --
  -- Table structure for table `location`
  --
  
  DROP TABLE IF EXISTS `location`;
  /*!40101 SET @saved_cs_client     = @@character_set_client */;
  /*!50503 SET character_set_client = utf8mb4 */;
  CREATE TABLE `location` (
    `location_id` int unsigned NOT NULL,
    `location_name` varchar(255) DEFAULT NULL,
    `latitude` varchar(12) DEFAULT NULL,
    `longitude` varchar(12) DEFAULT NULL,
    `is_checked` tinyint DEFAULT NULL,
    PRIMARY KEY (`location_id`),
    UNIQUE KEY `location_id_UNIQUE` (`location_id`)
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
  /*!40101 SET character_set_client = @saved_cs_client */;
  
  --
  -- Table structure for table `user_credential`
  --
  
  DROP TABLE IF EXISTS `user_credential`;
  /*!40101 SET @saved_cs_client     = @@character_set_client */;
  /*!50503 SET character_set_client = utf8mb4 */;
  CREATE TABLE `user_credential` (
    `user_id` int unsigned DEFAULT NULL,
    `password_hash` varchar(255) NOT NULL,
    `role` varchar(255) DEFAULT NULL,
    PRIMARY KEY (`password_hash`),
    KEY `fk_credentials_users_idx` (`user_id`),
    CONSTRAINT `fk_credentials_users` FOREIGN KEY (`user_id`) REFERENCES `user_t` (`user_id`)
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
  /*!40101 SET character_set_client = @saved_cs_client */;
  
  --
  -- Table structure for table `user_preference`
  --
  
  DROP TABLE IF EXISTS `user_preference`;
  /*!40101 SET @saved_cs_client     = @@character_set_client */;
  /*!50503 SET character_set_client = utf8mb4 */;
  CREATE TABLE `user_preference` (
    `user_id` int unsigned DEFAULT NULL,
    `weather` varchar(255) DEFAULT NULL,
    `push_notifications` tinyint DEFAULT NULL,
    `mail_notifications` tinyint DEFAULT NULL,
    `cookies` tinyint DEFAULT NULL,
    KEY `fk_preferences_users_idx` (`user_id`),
    CONSTRAINT `fk_preferences_users` FOREIGN KEY (`user_id`) REFERENCES `user_t` (`user_id`)
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
  /*!40101 SET character_set_client = @saved_cs_client */;
  
  --
  -- Table structure for table `user_session`
  --
  
  DROP TABLE IF EXISTS `user_session`;
  /*!40101 SET @saved_cs_client     = @@character_set_client */;
  /*!50503 SET character_set_client = utf8mb4 */;
  CREATE TABLE `user_session` (
    `session_id` varchar(255) NOT NULL,
    `user_id` int unsigned DEFAULT NULL,
    `opened` datetime DEFAULT NULL,
    `active` tinyint DEFAULT NULL,
    PRIMARY KEY (`session_id`),
    UNIQUE KEY `session_id_UNIQUE` (`session_id`),
    KEY `fk_sessions_users_idx` (`user_id`),
    CONSTRAINT `fk_sessions_users` FOREIGN KEY (`user_id`) REFERENCES `user_t` (`user_id`)
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
  /*!40101 SET character_set_client = @saved_cs_client */;
  
  --
  -- Table structure for table `user_t`
  --
  
  DROP TABLE IF EXISTS `user_t`;
  /*!40101 SET @saved_cs_client     = @@character_set_client */;
  /*!50503 SET character_set_client = utf8mb4 */;
  CREATE TABLE `user_t` (
    `user_id` int unsigned NOT NULL,
    `email` varchar(255) DEFAULT NULL,
    `first_name` varchar(255) DEFAULT NULL,
    `last_name` varchar(255) DEFAULT NULL,
    `gender` varchar(255) DEFAULT NULL,
    `dob` datetime DEFAULT NULL,
    `location_id` int DEFAULT NULL,
    `user_type` varchar(255) DEFAULT NULL,
    PRIMARY KEY (`user_id`),
    UNIQUE KEY `id_UNIQUE` (`user_id`)
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
  /*!40101 SET character_set_client = @saved_cs_client */;
  
  --
  -- Table structure for table `walk`
  --
  
  DROP TABLE IF EXISTS `walk`;
  /*!40101 SET @saved_cs_client     = @@character_set_client */;
  /*!50503 SET character_set_client = utf8mb4 */;
  CREATE TABLE `walk` (
    `walk_id` int unsigned NOT NULL,
    `user_id` int unsigned DEFAULT NULL,
    `location_id` int unsigned DEFAULT NULL,
    `weather_type` varchar(255) DEFAULT NULL,
    `time` datetime DEFAULT NULL,
    `duration` int DEFAULT NULL,
    `rating` int DEFAULT NULL,
    `details` varchar(2048) DEFAULT NULL,
    `notify` tinyint DEFAULT NULL,
    PRIMARY KEY (`walk_id`),
    UNIQUE KEY `walk_id_UNIQUE` (`walk_id`),
    KEY `fk_walks_users_idx` (`user_id`),
    KEY `fk_locations_users_idx` (`location_id`),
    CONSTRAINT `fk_walks_locations` FOREIGN KEY (`location_id`) REFERENCES `location` (`location_id`),
    CONSTRAINT `fk_walks_users` FOREIGN KEY (`user_id`) REFERENCES `user_t` (`user_id`)
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
  /*!40101 SET character_set_client = @saved_cs_client */;
  SET @@SESSION.SQL_LOG_BIN = @MYSQLDUMP_TEMP_LOG_BIN;
  /*!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 2021-04-26 10:51:16
  