ㅁㅁㅁ
Tables (8)
Corporate
- corporate_id — BIGINT — Primary key — NOT NULL
- name — VARCHAR(255) — NOT NULL
- max — INT
- owner_id (user_id) — BIGINT — Foreign key → User.user_id — NOT NULL
CorporateFile
- corporate_file_id — BIGINT — Primary key — NOT NULL
- file_path — VARCHAR(255) — NOT NULL
- uploaded_at — DATETIME — NOT NULL
- corporate_id — BIGINT — Foreign key → Corporate.corporate_id — NOT NULL
- subject_id — BIGINT — Foreign key → Subject.subject_id
Payment
- payment_id — BIGINT — Primary key — NOT NULL
- amount — DECIMAL(10, 2) — NOT NULL
- date — DATETIME — NOT NULL
- user_id — BIGINT — Foreign key → User.user_id — NOT NULL
PaymentDetail
- payment_detail_id — BIGINT — Primary key — NOT NULL
- item_description — VARCHAR(255) — NOT NULL
- quantity — INT — NOT NULL
- price — DECIMAL(10, 2) — NOT NULL
- payment_id — BIGINT — Foreign key → Payment.payment_id — NOT NULL
Subject
- subject_id — BIGINT — Primary key — NOT NULL
- name — VARCHAR(255) — NOT NULL
SubjectCourse
- subject_course_id — BIGINT — Primary key — NOT NULL
- name — VARCHAR(255) — NOT NULL
- description — TEXT
- subject_id — BIGINT — Foreign key → Subject.subject_id — NOT NULL
- day — BIGINT — NOT NULL
- Field
User
- user_id — BIGINT — Primary key — NOT NULL
- name — VARCHAR(255) — NOT NULL
- email — VARCHAR(255) — NOT NULL
- role — ENUM('individual', 'corporate_member', 'free') — NOT NULL
- password — VARCHAR(255) — NOT NULL
- provide — ENUM('default', 'kakao', 'gmail')
user_corporate
- user_id — BIGINT — Foreign key → User.user_id — NOT NULL
- corporate_id — BIGINT — Foreign key → Corporate.corporate_id — NOT NULL