News Feed

Tables (6)

Comment (댓글)

  • comment_id (댓글 id) — NOT NULL — Primary key — NOT NULL
  • user_id (유저 id) — NOT NULL — Foreign key → User.user_id — NOT NULL
  • post_id (게시물 id) — NOT NULL — Foreign key → Post.post_id — NOT NULL
  • comment_content (댓글 내용) — NOT NULL
  • created_at (작성일) — NOT NULL
  • updated_at (수정일) — NOT NULL

Comment_like (댓글 좋아요)

  • comment_like_id (댓글 좋아요 id) — NOT NULL — Primary key — NOT NULL
  • comment_id (댓글 id) — NOT NULL — Foreign key → Comment.comment_id — NOT NULL
  • user_id (유저 id) — NOT NULL — Foreign key → User.user_id — NOT NULL
  • created_at (좋아요 누른 일자) — NOT NULL

Friend_request (Untitled)

  • friend_id (친구 id) — NOT NULL — Primary key — NOT NULL
  • to_user_id (친구요청 받은 유저 id) — NOT NULL — Foreign key → User.user_id — NOT NULL
  • from_user_id (친구요청 보낸 유저 id) — NOT NULL — Foreign key → User.user_id — NOT NULL
  • created_at (친구요청 일자) — NOT NULL
  • updated_at (요청수락여부 일자) — NOT NULL
  • status (수락여부(WAITING/CONFIRM)) — VARCHAR

Post (게시글)

  • post_id (게시물 id) — NOT NULL — Primary key — NOT NULL
  • user_id (유저 id) — NOT NULL — Foreign key → User.user_id — NOT NULL
  • title (게시물 제목) — NOT NULL
  • post_content (게시물 내용) — NOT NULL
  • created_at (작성일) — NOT NULL
  • updated_at (수정일) — NOT NULL

Post_like (게시글 좋아요)

  • post_like_id (게시글 좋아요 id) — NOT NULL — Primary key — NOT NULL
  • post_id (좋아요 눌린 게시글 id) — NOT NULL — Foreign key → Post.post_id — NOT NULL
  • user_id (좋아요 누른 사용자 id) — NOT NULL — Foreign key → User.user_id — NOT NULL
  • created_at (좋아요 누른 일자) — NOT NULL

User (유저)

  • user_id (유저 id) — NOT NULL — Primary key — NOT NULL
  • user_name (유저명) — NOT NULL
  • email (이메일) — NOT NULL
  • password (비밀번호) — NOT NULL
  • created_at (작성일) — NOT NULL
  • updated_at (수정일) — NOT NULL
  • deleted_at (삭제일) — NULL