Update of probono_DB_2
Tables (8)
attendance (Untitled)
- Key — Primary key — NOT NULL
- Field
classes (Untitled4)
- classId (Key) — bigint — Primary key — NOT NULL — autoincrement
- year (Field) — integer — NOT NULL
- grade (Field2) — enum — NOT NULL
- section (Field3) — enum — NOT NULL
- status (Field4) — NOT NULL
- createdAt (Field5) — NOT NULL
- updatedAt (Field6)
- createdChargeId (Field7) — NOT NULL
- updatedChargeId (Field8)
course (Untitled10)
- courseId (Key3) — bigint — Primary key — NOT NULL
- status (Field) — enum — NOT NULL
- createdAt (Field2) — timestamp — NOT NULL
- updatedAt (Field3) — timestamp
- subjectId (Key4) — bigint — Foreign key → subject.subjectId — NOT NULL — autoincrement
- createdChargeId (Field4) — bigint — NOT NULL
- updatedChargeId (Field5) — bigint
- classId (Key) — bigint — Foreign key → classes.classId — NOT NULL — autoincrement
course_user (Untitled11)
- cuId (Key) — bigint — Primary key — NOT NULL
- status (Field) — NOT NULL
- createdAt (Field2) — NOT NULL
- updatedAt (Field3)
- createdChargeId (Field4) — NOT NULL
- updatedChargeId (Field5)
- courseId (Key32) — Foreign key → course.courseId — NOT NULL — index
- loginId (Key3) — Foreign key → users.loginId — NOT NULL — index
- role (Field6) — ENUM — NOT NULL
image (Untitled6)
- imageId (Key) — bigint — Primary key — NOT NULL
- imagePath (Field2) — varchar(2048) — NOT NULL
- status (Field) — 'ACTIVE', 'INACTIVE' — NOT NULL
- createdAt (Field3)
- updatedAt (Field4)
- noticeId (Key2) — bigint — Foreign key → notice.noticeId
- createdChargeId (Field5)
- updatedChargeId (Field6)
notice (Untitled5)
- noticeId (Key) — bigint — Primary key — NOT NULL
- title (Field) — varchar(100) — NOT NULL
- content (Field2) — text
- status (Field4) — NOT NULL
- createdAt (Field5) — NOT NULL
- updatedAt (Field6)
- createdChargeId (Field3) — NOT NULL
- updatedChargeId (Field7)
- views (Field8) — integer — NOT NULL
- loginId (Key2) — Foreign key → users.loginId — NOT NULL
- classId (Key3) — Foreign key → classes.classId — autoincrement, index
- type (Field9) — ENUM — NOT NULL
- courseId (Key33) — Foreign key → course.courseId — index
subject (Untitled3)
- subjectId (Key) — bigint — Primary key — NOT NULL — autoincrement
- name (Field) — varchar(20) — NOT NULL — Unique
- isElective (Field2) — bool — NOT NULL
- status (Field3) — NOT NULL
- createdAt (Field4) — NOT NULL
- updatedAt (Field5)
- createdChargeId (Field6) — NOT NULL
- updatedChargeId (Field7)
users (Untitled13)
- loginId (Key) — varchar(20) — Primary key — NOT NULL
- loginPw (Field) — varchar(255) — NOT NULL
- name (Field2) — varchar(40) — NOT NULL
- serialNumber (Field13) — integer — NOT NULL — Unique
- sex (Field3) — enum
- phoneNum (Field4) — varchar(20)
- pwAnswer (Field10) — varchar(50)
- birth (Field11) — date
- fatherPhoneNum (Field14) — varchar(20)
- motherPhoneNum (Field15) — varchar(20)
- guardiansPhoneNum (Field16) — varchar(20)
- role (Field12) — enum — NOT NULL
- status (Field5) — enum — NOT NULL
- createdAt (Field6) — timestamp — NOT NULL
- updatedAt (Field7) — timestamp
- createdChargeId (Field8) — bigint — NOT NULL
- updatedChargeId (Field9) — bigint
- classId (Key2) — bigint — Foreign key → classes.classId — autoincrement
- imageId (Key3) — bigint — Foreign key → image.imageId
- grade (Field17) — enum