/*
SQLyog Ultimate v13.2.0 (64 bit)
MySQL - 8.0.33-0ubuntu0.20.04.2 : Database - teamtriv_teamtrivia
*********************************************************************
*/

/*!40101 SET NAMES utf8 */;

/*!40101 SET SQL_MODE=''*/;

/*!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 */;
CREATE DATABASE /*!32312 IF NOT EXISTS*/`teamtriv_teamtrivia` /*!40100 DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci */ /*!80016 DEFAULT ENCRYPTION='N' */;

/*Table structure for table `feud_responses_host` */

DROP TABLE IF EXISTS `feud_responses_host`;

CREATE TABLE `feud_responses_host` (
  `aID` int NOT NULL AUTO_INCREMENT,
  `sID` int DEFAULT NULL,
  `response_rank` int DEFAULT NULL,
  `response` varchar(100) CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci DEFAULT NULL,
  `hint` char(1) CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci DEFAULT NULL,
  `date_updated` datetime DEFAULT NULL,
  `updated_by` int DEFAULT NULL,
  `region_ID` int DEFAULT '0',
  `user_ID` int DEFAULT '0',
  `responses_master_ID` int DEFAULT NULL,
  `surveys_master_ID` int DEFAULT NULL,
  `responses_region_master_ID` int DEFAULT NULL,
  `surveys_region_master_ID` int DEFAULT NULL,
  `set_ID` int DEFAULT NULL,
  PRIMARY KEY (`aID`)
) ENGINE=InnoDB AUTO_INCREMENT=156335 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

/*Table structure for table `feud_sets` */

DROP TABLE IF EXISTS `feud_sets`;

CREATE TABLE `feud_sets` (
  `set_ID` int NOT NULL AUTO_INCREMENT,
  `set_name` varchar(100) DEFAULT NULL,
  `added_by` int DEFAULT NULL,
  `date_created` datetime DEFAULT NULL,
  `weekstart` date DEFAULT NULL,
  `question_set_ID` int DEFAULT NULL,
  PRIMARY KEY (`set_ID`)
) ENGINE=InnoDB AUTO_INCREMENT=717 DEFAULT CHARSET=utf8mb3;

/*Table structure for table `feud_status` */

DROP TABLE IF EXISTS `feud_status`;

CREATE TABLE `feud_status` (
  `game_date` datetime DEFAULT NULL,
  `user_ID` int DEFAULT NULL,
  `sID` int DEFAULT NULL,
  `game_round` varchar(1) DEFAULT NULL,
  `qno` int DEFAULT NULL,
  `response_rank` int DEFAULT NULL,
  `response` varchar(100) DEFAULT NULL,
  `date_entered` datetime DEFAULT NULL,
  `view` varchar(15) DEFAULT NULL,
  `survey` text,
  `status_ID` int NOT NULL AUTO_INCREMENT,
  `team_rank` int DEFAULT NULL,
  PRIMARY KEY (`status_ID`)
) ENGINE=InnoDB AUTO_INCREMENT=42445 DEFAULT CHARSET=latin1;

/*Table structure for table `feud_surveys_host` */

DROP TABLE IF EXISTS `feud_surveys_host`;

CREATE TABLE `feud_surveys_host` (
  `sID` int NOT NULL DEFAULT '0',
  `s_host_ID` int NOT NULL AUTO_INCREMENT,
  `sRound` char(1) CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci DEFAULT NULL,
  `sNo` int DEFAULT NULL,
  `survey` text CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci,
  `response1` text CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci,
  `response2` text CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci,
  `response3` text CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci,
  `response4` text CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci,
  `response5` text CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci,
  `set_ID` int DEFAULT NULL,
  `date_added` datetime DEFAULT NULL,
  `subject` varchar(50) CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci DEFAULT NULL,
  `question_set_id` int DEFAULT NULL,
  `region_ID` int DEFAULT '0',
  `user_ID` int DEFAULT '0',
  `date_updated` datetime DEFAULT NULL,
  `updated_by` int DEFAULT NULL,
  `added_by` int DEFAULT NULL,
  `surveys_master_ID` int DEFAULT NULL,
  `surveys_region_master_ID` int DEFAULT NULL,
  PRIMARY KEY (`s_host_ID`)
) ENGINE=InnoDB AUTO_INCREMENT=31788 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
