인스타그램

테이블 (4)

comments (댓글)

  • id (Key) — bigint — 기본 키 — NOT NULL
  • post_id (Key2) — bigint — 외래 키 → posts.id — NOT NULL
  • content (Field) — text
  • created_at (Field2) — datetime
  • updated_at (Field3) — datetime

posts (게시물)

  • id (Key) — bigint — 기본 키 — NOT NULL
  • content (Field) — text
  • image_url (Field3) — varchar(255)
  • created_at (Field4) — datetime
  • updated_at (Field5) — datetime

replies (답글)

  • id (Key) — bigint — 기본 키 — NOT NULL
  • post_id (Key3) — bigint — 외래 키 → posts.id — NOT NULL
  • comment_id (Key2) — bigint — 외래 키 → comments.id — NOT NULL
  • content (Field) — text
  • created_at (Field2) — datetime
  • updated_at (Field3) — datetime

users (회원)

  • id (Key) — bigint — 기본 키 — NOT NULL
  • nickname (Field) — varchar(50)
  • profile_image (Field2) — multipartFile
  • create_at (Field3) — datetime
  • updated_at (Field4) — datetime