-
Notifications
You must be signed in to change notification settings - Fork 0
/
create_chuck_quotes_schema.sql
39 lines (31 loc) · 1.34 KB
/
create_chuck_quotes_schema.sql
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
-- MySQL Workbench Forward Engineering
SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0;
SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0;
SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='TRADITIONAL,ALLOW_INVALID_DATES';
-- -----------------------------------------------------
-- Schema chuck_quotes
-- -----------------------------------------------------
-- -----------------------------------------------------
-- Schema chuck_quotes
-- -----------------------------------------------------
CREATE SCHEMA IF NOT EXISTS `chuck_quotes` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci ;
USE `chuck_quotes` ;
-- -----------------------------------------------------
-- Table `chuck_quotes`.`users`
-- -----------------------------------------------------
CREATE TABLE IF NOT EXISTS `chuck_quotes`.`users` (
`username` VARCHAR(45) NOT NULL,
`password` VARCHAR(45) NOT NULL,
PRIMARY KEY (`username`))
ENGINE = InnoDB;
-- -----------------------------------------------------
-- Table `chuck_quotes`.`quotes`
-- -----------------------------------------------------
CREATE TABLE IF NOT EXISTS `chuck_quotes`.`quotes` (
`id` INT NOT NULL AUTO_INCREMENT,
`text` VARCHAR(255) NOT NULL,
PRIMARY KEY (`id`))
ENGINE = InnoDB;
SET SQL_MODE=@OLD_SQL_MODE;
SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS;
SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS;