Qurve

Tables (14)

AiChatMessage (TB_AI_CHAT_MESSAGE)

  • messageId (message_id) — INT — Primary key — NOT NULL — 메시지 ID
  • roomId (room_id) — INT — Foreign key → AiChatRoom.roomId — NOT NULL — 채팅방 ID
  • senderType (sender_type) — VARCHAR(255) — NOT NULL — USER / AI
  • message — VARCHAR(2550) — NOT NULL — 메시지 내용
  • createdAt (created_at) — DATETIME — NOT NULL — 생성 시간

AiChatRoom (TB_AI_CHAT_ROOM)

  • roomId (room_id) — INT — Primary key — NOT NULL — 채팅방 ID
  • userId (user_id) — INT — Foreign key → User.userId — NOT NULL — 사용자 ID
  • topic — VARCHAR(255) — NOT NULL — 회화 주제

Bookmark (TB_BOOKMARK)

  • bookmarkId (bookmark_id) — INT — Primary key — NOT NULL
  • userId (user_id) — INT — Foreign key → User.userId — NOT NULL — 사용자 ID
  • wordId (word_id) — VARCHAR(50) — NOT NULL — 단어 ID
  • japanese — VARCHAR(50) — NOT NULL — 일본어
  • reading — VARCHAR(50) — NOT NULL — 히라가나
  • meaning — VARCHAR(255) — NOT NULL — 뜻
  • level — VARCHAR(10) — 레벨
  • createdAt (created_at) — DATETIME — NOT NULL — 기록 시간

Challenge (TB_CHALLENGE)

  • challengeId (challenge_id) — INT — Primary key — NOT NULL — 챌린지 ID
  • userId (user_id) — INT — Foreign key → User.userId — NOT NULL — 사용자 ID
  • title — VARCHAR(255) — NOT NULL — 챌린지 제목
  • targetType (target_type) — VARCHAR(255) — NOT NULL — 목표 유형
  • targetValue (target_value) — INT — NOT NULL — 목표 값
  • startDate (start_date) — DATETIME — NOT NULL — 시작일
  • endDate (end_date) — DATETIME — NOT NULL — 종료일
  • repeatDays (repeat_days) — VARCHAR(50) — NOT NULL — 반복 요일
  • status — ENUM('IN_PROGRESS','COMPLETED','FAILED') — NOT NULL — 챌린지 진행 상태 (IN_PROGRESS / COMPLETED / FAILED)
  • alarmEnabled (alarm_enabled) — BOOLEAN — 챌린지 알림 활성화 여부
  • alarmTime (alarm_time) — DATETIME — 챌린지 알림 시간

ChallengeProgress (TB_CHALLENGE_PROGRESS)

  • progressId (progress_id) — INT — Primary key — NOT NULL — 진행률 ID
  • challengeId (challenge_id) — INT — Foreign key → Challenge.challengeId — NOT NULL — 챌린지 ID
  • completedDays (completed_days) — INT — NOT NULL — 완료 일수

DailyStudyLog (TB_DAILY_STUDY_LOG)

  • logId (log_id) — INT — Primary key — NOT NULL — 로그 ID
  • userId (user_id) — INT — Foreign key → User.userId — NOT NULL — 사용자 ID
  • studyTime (study_time) — INT — NOT NULL — 학습 시간
  • solvedQuiz (solved_quiz) — INT — NOT NULL — 풀이 문제 수
  • createdAt (created_at) — DATETIME — NOT NULL — 기록 시간

LevelTestResult (TB_LEVEL_TEST_RESULT)

  • resultId (result_id) — INT — Primary key — NOT NULL — 결과 ID
  • userId (user_id) — INT — Foreign key → User.userId — NOT NULL — 사용자 ID
  • score — INT — NOT NULL — 점수
  • levelResult (level_result) — VARCHAR(255) — NOT NULL — 결과 레벨
  • createdAt (created_at) — DATETIME — NOT NULL — 테스트 일시

Problem (TB_PROBLEM)

  • ProblemId (Problem_id) — INT — Primary key — NOT NULL — 문제ID
  • level — VARCHAR(10) — NOT NULL — 레벨
  • category — VARCHAR(50) — NOT NULL — 문제유형
  • subType (sub_type) — VARCHAR(50) — NOT NULL
  • questionFormat (question_format) — VARCHAR(30) — NOT NULL
  • passageText (passage_text) — TEXT
  • answerIndex (answer_index) — INT — NOT NULL
  • explanation — TEXT — NOT NULL
  • sourceType (source_type) — VARCHAR(30) — NOT NULL
  • reviewStatus (review_status) — VARCHAR(30) — NOT NULL
  • isActive (is_active) — BOOLEAN — NOT NULL
  • createdAt (created_at) — DATETIME — NOT NULL
  • updatedAt (updated_at) — DATETIME — NOT NULL

Problem_attempt (TB_PROBLEM_ATTEMPT)

  • attemptId (attempt_id) — INT — Primary key — NOT NULL
  • userId (user_id) — INT — Foreign key → User.userId — NOT NULL — 사용자 ID
  • wrongId (wrong_id) — INT — Foreign key → WrongNote.wrongId — NOT NULL — 오답 ID
  • ProblemId (Problem_id) — INT — Foreign key → Problem.ProblemId — NOT NULL — 문제ID
  • selectedChoiceNumber (selected_choice_number) — INT — NOT NULL
  • isCorrect (is_correct) — BOOLEAN — NOT NULL
  • solvingTimeSec (solving_time_sec) — INT
  • createdAt (created_at) — DATETIME — NOT NULL

Problem_choice (TB_PROBLEM_CHOICE)

  • choiceId (choice_id) — INT — Primary key — NOT NULL
  • ProblemId (Problem_id) — INT — Foreign key → Problem.ProblemId — NOT NULL — 문제ID
  • choiceNumber (choice_number) — INT — NOT NULL
  • choiceText (choice_text) — VARCHAR(500) — NOT NULL

StudyStatistics (TB_STUDY_STATISTICS)

  • statisticsId (statistics_id) — INT — Primary key — NOT NULL — 통계 ID
  • userId (user_id) — INT — Foreign key → User.userId — NOT NULL — 사용자 ID
  • totalStudyTime (total_study_time) — INT — NOT NULL — 총 학습 시간
  • totalSolvedQuiz (total_solved_quiz) — INT — NOT NULL — 총 풀이 문제 수
  • averageAccuracy (average_accuracy) — INT — NOT NULL — 평균 정답률
  • streakDays (streak_days) — INT — NOT NULL — 연속 학습 일수
  • updatedAt (updated_at) — DATETIME — NOT NULL — 마지막 갱신 시간

UnitProgress (TB_UNIT_PROGRESS)

  • unitProgressId (unit_progress_id) — INT — Primary key — NOT NULL
  • userId (user_id) — INT — Foreign key → User.userId — NOT NULL — 사용자 ID
  • level — VARCHAR(10) — NOT NULL — 레벨
  • unitNumber (unit_number) — INT — NOT NULL — 유닛 번호
  • status — VARCHAR(20) — NOT NULL — 학습 상태
  • updatedAt (updated_at) — DATETIME — NOT NULL — 업데이트 시간

User (TB_USER)

  • userId (user_id) — INT — Primary key — NOT NULL — 사용자 ID
  • loginId (login_id) — INT — NOT NULL — 사용자 로그인 ID
  • passwordHash (password_hash) — VARCHAR(255) — NOT NULL — BCrypt 암호화 비밀번호
  • email — VARCHAR(255) — NOT NULL — 이메일
  • name — VARCHAR(20) — NOT NULL — 사용자 이름
  • nickname — VARCHAR(30) — NOT NULL — 닉네임
  • profileImage (profile_image) — VARCHAR(1000) — 프로필 이미지
  • learningGoal (learning_goal) — VARCHAR(255) — 학습 목표
  • currentLevel (current_level) — VARCHAR(255) — 현재 레벨
  • targetLanguage (target_language) — VARCHAR(255) — 목표 언어
  • role — ENUM('USER', 'ADMIN') — NOT NULL — 사용자 권한 (USER / ADMIN)
  • isDeleted (is_deleted) — BOOLEAN — NOT NULL — 계정 삭제 여부
  • socialProviderId (social_provider_id) — INT — 소셜 로그인 식별값
  • emailVerified (email_verified) — BOOLEAN — NOT NULL — 이메일 인증 여부
  • createdAt (created_at) — DATETIME — NOT NULL — 가입일
  • refreshToken (refresh_token) — VARCHAR(520) — JWT 재발급 토큰
  • refreshTokenExpiredAt (refresh_token_expired_at) — DATETIME — 재발급 토큰 만료시간

WrongNote (TB_WRONG_NOTE)

  • wrongId (wrong_id) — INT — Primary key — NOT NULL — 오답 ID
  • userId (user_id) — INT — Foreign key → User.userId — NOT NULL — 사용자 ID
  • ProblemId (Problem_id) — INT — Foreign key → Problem.ProblemId — NOT NULL — 문제ID
  • userAnswer (user_answer) — VARCHAR(255) — 사용자 답안
  • correctAnswer (correct_answer) — VARCHAR(255) — NOT NULL — 정답
  • createdAt (created_at) — DATETIME — NOT NULL — 기록 시간