1111
Tables (7)
bookings
- booking_id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → users.user_id — NOT NULL
- session_id — BIGINT — Foreign key → course_sessions.session_id — NOT NULL
- status — ENUM('PENDING_PAYMENT', 'CONFIRMED', 'CANCELLED', 'REFUNDED')
- payment_deadline — TIMESTAMP
- created_at — TIMESTAMP
categories
- category_id — BIGINT — Primary key — NOT NULL
- name — VARCHAR(50) — NOT NULL
course_sessions
- session_id — BIGINT — Primary key — NOT NULL
- course_id — BIGINT — Foreign key → courses.course_id — NOT NULL
- start_at — TIMESTAMP — NOT NULL
- end_at — TIMESTAMP — NOT NULL
- max_capacity — INT — NOT NULL
- current_count — INT
courses
- course_id — BIGINT — Primary key — NOT NULL
- instructor_id — BIGINT — Foreign key → users.user_id — NOT NULL
- category_id — BIGINT — Foreign key → categories.category_id — NOT NULL
- title — VARCHAR(200) — NOT NULL
- description — TEXT
- price — DECIMAL(10, 2) — NOT NULL
- open_at — TIMESTAMP — NOT NULL
- status — ENUM('PREPARING', 'OPEN', 'CLOSED')
- created_at — TIMESTAMP
onboarding
- onboarding_id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → users.user_id — NOT NULL
- goal — TEXT
- level — ENUM('BEGINNER', 'INTERMEDIATE', 'ADVANCED')
- interest_category_id — BIGINT
- updated_at — TIMESTAMP
users
- user_id — BIGINT — Primary key — NOT NULL
- email — VARCHAR(100) — NOT NULL
- password — VARCHAR(255)
- name — VARCHAR(50) — NOT NULL
- role — ENUM('STUDENT', 'INSTRUCTOR', 'ADMIN') — NOT NULL
- social_provider — ENUM('LOCAL', 'GOOGLE', 'KAKAO')
- social_id — VARCHAR(255)
- created_at — TIMESTAMP
waiting_lines
- waiting_id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → users.user_id — NOT NULL
- session_id — BIGINT — NOT NULL
- waiting_number — INT — NOT NULL
- status — ENUM('WAITING', 'PROMOTED', 'EXPIRED')
- created_at — TIMESTAMP