newsfeed

Tables (6)

Comments (댓글)

  • comment_id (Key) — Primary key — NOT NULL
  • post_id (Key2) — Foreign key → Posts.post_id — NOT NULL
  • user_id (Key3) — Foreign key → User.user_id — NOT NULL
  • content (Field) — NOT NULL
  • likeCount (Field5) — NOT NULL
  • created_at (Field2) — NOT NULL
  • updated_at (Field3) — NOT NULL
  • deleted_at (Field4)

Follows (팔로우)

  • follow_id (Key) — Primary key — NOT NULL
  • from_user (Key2) — Foreign key → User.user_id — NOT NULL
  • to_user (Key3) — Foreign key → User.user_id — NOT NULL

Like_Comment (댓글 좋아요)

  • like_comment_id (Key) — Primary key — NOT NULL
  • comment_id (Key2) — Foreign key → Comments.comment_id — NOT NULL
  • user_id (Key3) — Foreign key → User.user_id — NOT NULL
  • created_at (Field) — NOT NULL

Like_Post (게시글 좋아요)

  • like_post_id (Key) — Primary key — NOT NULL
  • post_id (Key2) — Foreign key → Posts.post_id — NOT NULL
  • user_id (Key3) — Foreign key → User.user_id — NOT NULL
  • created_at (Field) — NOT NULL

Posts (게시글)

  • post_id (Key) — Primary key — NOT NULL
  • user_id (Key2) — Foreign key → User.user_id — NOT NULL
  • content (Field) — NOT NULL
  • likeCount (Field5) — NOT NULL
  • created_at (Field2) — NOT NULL
  • updated_at (Field3) — NOT NULL
  • deleted_at (Field4)

User (유저)

  • user_id (Key) — Primary key — NOT NULL
  • email (Field) — NOT NULL
  • username (Field3) — NOT NULL
  • password (Field2) — NOT NULL
  • followCount (Field7) — NOT NULL
  • followingCount (Field8) — NOT NULL
  • created_at (Field4) — NOT NULL
  • updated_at (Field5) — NOT NULL
  • deleted_at (Field6)