KCC DB 설계

테이블 (5)

comment (Untitled3)

  • comment_id (Key) — INT — 기본 키 — NOT NULL
  • post_id (Key2) — INT — 외래 키 → post.post_id — NOT NULL
  • user_id (Key22) — INT — 외래 키 → post.user_id — NOT NULL
  • comment_date (Field) — TIMESTAMP
  • comment_content (Field2) — VARCHAR
  • comment_status (Field3) — CHAR

event (Untitled4)

  • event_id (Key) — INT — 기본 키 — NOT NULL
  • post_id (Key2) — INT — 외래 키 → post.post_id — NOT NULL
  • user_id (Key22) — INT — 외래 키 → post.user_id — NOT NULL
  • event_name (Field) — CHAR
  • event_description (Field2) — VARCHAR
  • start_date (Field3) — TIMESTAMP
  • end_date (Field4) — TIMESTAMP
  • status (Field5) — CHAR
  • point (Field6) — INT

point (Untitled5)

  • point_id (Key) — INT — 기본 키 — NOT NULL
  • user_id (Key2) — INT — 외래 키 → user.user_id — NOT NULL
  • post_id (Key4) — INT — 외래 키 → post.post_id — NOT NULL
  • event_id (Key3) — INT — 외래 키 → event.event_id — NOT NULL
  • point_change (Field) — INT
  • change_date (Field2) — TIMESTAMP

post (Untitled2)

  • post_id (Key) — INT — 기본 키 — NOT NULL
  • user_id (Key2) — INT — 외래 키 → user.user_id — NOT NULL
  • post_date (Field2) — TIMESTAMP
  • post_content (Field3) — VARCHAR
  • post_title (Field4) — CHAR
  • post_status (Field5) — CHAR
  • comment_status (Field6) — CHAR
  • event_type (Field7) — CHAR

user (Untitled)

  • user_id (Key) — INT — 기본 키 — NOT NULL
  • user_registered (Field) — TIMESTAMP
  • user_email (Field2) — CHAR
  • user_pw (Field3) — CHAR
  • user_name (Field4) — CHAR
  • user_phone (Field5) — CHAR
  • user_grade (Field6) — TINYINT
  • display_name (Field7) — CHAR
  • user_status (Field8) — CHAR