ㅁㅁ

Tables (11)

Comments

  • comments_id — INT — Primary key — NOT NULL
  • world_cup_id — INT — Foreign key → WorldCup.world_cup_id — NOT NULL
  • user_id — INT — Foreign key → Users.user_id — NOT NULL
  • content — varchar(255)
  • comments_created_at — TIMESTAMP

Human

  • progress_id — INT — Foreign key → Progress.progress_id — NOT NULL
  • candidate_id — INT — Foreign key → candidate.candidate_id — NOT NULL
  • status — INT

Likes

  • user_id — INT — Foreign key → Users.user_id — NOT NULL
  • world_cup_id — INT — Foreign key → WorldCup.world_cup_id — NOT NULL

Post

  • post_id — INT — Primary key — NOT NULL
  • user_id — INT — Foreign key → Users.user_id — NOT NULL
  • content — varchar(255)
  • title — varchar(50)
  • post_created_at — TIMESTAMP

Progress

  • progress_id — INT — Primary key — NOT NULL
  • user_id — INT — Foreign key → Users.user_id — NOT NULL
  • world_cup_id — INT — Foreign key → WorldCup.world_cup_id — NOT NULL

Users

  • user_id — INT — Primary key — NOT NULL
  • name — varchar(20)
  • password — varchar(255)
  • image — varchar(255)
  • role_code — varchar(10)

VoteHistory

  • vote_history_id — INT — Primary key — NOT NULL
  • candidate_id — INT — Foreign key → candidate.candidate_id — NOT NULL
  • user_id — INT — Foreign key → Users.user_id — NOT NULL
  • world_cup_id — INT — Foreign key → WorldCup.world_cup_id — NOT NULL

WorldCup

  • world_cup_id — INT — Primary key — NOT NULL
  • start_date — TIMESTAMP
  • end_date — TIMESTAMP
  • award — varchar(255)
  • code_id — INT — Foreign key → WorldCupCode.code_id — NOT NULL

WorldCupCode

  • code_id — INT — Primary key — NOT NULL
  • title — varchar(100)
  • image — varchar(255)
  • description — varchar(100)

WorldCupResult

  • world_cup_result_id — INT — Primary key — NOT NULL
  • grade — INT
  • world_cup_id — INT — Foreign key → WorldCup.world_cup_id — NOT NULL
  • candidate_id — INT — Foreign key → candidate.candidate_id — NOT NULL

candidate

  • candidate_id — INT — Primary key — NOT NULL
  • user_id — INT — Foreign key → Users.user_id — NOT NULL
  • world_cup_id — INT — Foreign key → WorldCup.world_cup_id — NOT NULL
  • vote — INT