Song For You

Tables (7)

AI_Chat (Chat)

  • chat_id — BIGINT — Primary key
  • user_id — BIGINT — Foreign key → User.user_id
  • message — VARCHAR(1000) — NOT NULL
  • sender_type — ENUM('USER', 'AI') — NOT NULL
  • chat_time — DATETIME — NOT NULL

Developer_Request

  • request_id — BIGINT — Primary key
  • request_title — VARCHAR(100) — NOT NULL
  • request_message — VARCHAR(500) — NOT NULL
  • response_message — VARCHAR(500)
  • status — ENUM('PENDING', 'IN_PROGRESS', 'RESOLVED') — NOT NULL
  • request_time — DATETIME — NOT NULL
  • user_id (user_id2) — BIGINT — Foreign key → User.user_id

Genre

  • genre_id — BIGINT — Foreign key → User_Genre.genre_id — NOT NULL
  • genre_name — VARCHAR(50) — NOT NULL

RecommendMusic

  • recommend_id — BIGINT — Primary key
  • chat_id — BIGINT — Foreign key → AI_Chat.chat_id
  • user_id — BIGINT — Foreign key → AI_Chat.user_id
  • song_title — VARCHAR(100) — NOT NULL
  • artist — VARCHAR(100) — NOT NULL
  • recommend_reason — VARCHAR(500) — NOT NULL
  • cheer_message — VARCHAR(500) — NOT NULL
  • like_status — ENUM('LIKE', 'DISLIKE', 'NEUTRAL') — NOT NULL
  • inquiry_message — VARCHAR(500)
  • instagram_share_url — VARCHAR(255)
  • song_url — VARCHAR(255)
  • saved_to_library — BOOLEAN — NOT NULL
  • save_time — DATETIME — NOT NULL
  • INDEX — idx_user_id

User

  • user_id — BIGINT — Primary key
  • userName — VARCHAR(50) — NOT NULL
  • nickName — VARCHAR(50) — NOT NULL
  • access_token — TEXT
  • refresh_token — TEXT
  • kakao_id — VARCHAR(50) — NOT NULL

UserProfile

  • userprofile_id — BIGINT — Primary key — NOT NULL
  • user_id — BIGINT — Foreign key → User.user_id
  • aiMusicRecommendCount — INT — NOT NULL
  • recommendMethod — ENUM('AI', 'USER') — NOT NULL
  • user_status — 'NORMAL', 'WARNING', 'SUSPENDED', 'FORCED_WITHDRAWAL', 'VOLUNTARY_WITHDRAWAL' — NOT NULL
  • phone_number — VARCHAR(20)
  • created_at — TIMESTAMP — NOT NULL

User_Genre

  • genre_id — BIGINT — Primary key — NOT NULL
  • user_id — BIGINT — Foreign key → User.user_id — NOT NULL