0% found this document useful (0 votes)
50 views

Database Design

Uploaded by

mahmudul21124
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
50 views

Database Design

Uploaded by

mahmudul21124
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 8

4.

3 Database Design

User
Primary Key: user_id
Field Names Data type Data Size Description
user_id Text 10 User’s Username
user_password Text 8 User’s password
fname Text 30 User First Name
lname Text 30 User Last Name
personal_email Text 50 User Email address
dob Date 10 Date of birth
id_number Text 12 User NIC number
no Text 10 Number of the Address
street Text 100 Street of the Address
city Text 30 City of the Address
gender Text 10 User’s Gender
Record Size 300
Table 1 User

Admin
Primary Key: user_id
Field Names Data type Data Size Description
user_id Text 10 Admin’s Username
description Text 30 Type of Admin
Record Size 40
Table 2 Admin

Student
Primary Key: user_id

Field Names Data type Data Size Description


user_id Text 10 Student’s Username
guardian_fname Text 30 Student guardian first
name
guardian_lname Text 30 Student guardian last name
final_qualification Text 20 Student final qualification
Record Size 90
Table 3 Student

125
Teacher
Primary Keys: user_id, teacher_specialization
Foreign Key: user_id

Field Names Data type Data Size Description


user_id Text 10 Teacher’s Username
teacher_specialization Number 10 Teacher’s Specialization
Record Size 20
Table 4 Teacher

Student_Course
Primary Keys: user_id, course_id
Foreign Keys: user_id, course_id

Field Names Data type Data Size Description


user_id Text 10 Student’s Username
course_id Text 10 Course Id
register_date Date 10 Registration date
Record Size 30
Table 5 Student_Course

Course
Primary Key: course_id
Foreign Key: user_id
Field Names Data type Data Size Description
course_id Text 10 Course number
course_type Text 20 Course Type
course_description Text 150 Course Description
couse_name Text 50 Course Name
course_duration Number 05 Course duration
course_fee Number 15 Course fee
user_id Text 10 Teacher’s Username
Record Size 260
Table 6 Course

126
Payment
Primary key: payment_id
Field Names Data type Data Size Description
payment_id Number 5 Payment Id
payment_amount Number 10 Payment Amount
payment_description Text 30 Payment Description
Record Size 45
Table 7 Payment

Student_Course_Payment
Primary Keys: user_id, course_id, payment_id
Foreign Keys: user_id, course_id, payment_id
Field Names Data type Data Size Description
user_id Text 10 Student’s Username
course_id Text 10 Course Id
payment_id Number 5 Payment Id
payment_date Date 10 Payment Date
Record Size 35
Table 8 Student_Course_Payment

Student_Batch
Primary Keys: user_id, batch_id
Foreign Keys: user_id, batch_id

Field Names Data type Data Size Description


user_id Text 10 Student’s Username
batch_id Text 20 Batch Id
Record Size 30
Table 9 Student_Batch

127
Batch
Primary Key: batch_id
Foreign Keys: course_id, user_id

Field Names Data type Data Size Description


batch_id Text 20 Batch Id
batch_description Text 100 Batch description
course_id Text 10 Course Id
batch_strat_date Date 10 Batch Start Date
batch_end_date Date 10 Batch End Date
user_id Text 10 Teacher’s Username
Record Size 160
Table 10 Batch

Student_ExamSchedule
Primary Keys: user_id, exam_schedule_id
Foreign Keys: user_id, exam_schedule_id
Field Names Data type Data Size Description
user_id Text 10 Student’s Username
exam_shedule_id Text 20 Exam schedule Id
grade Text 10 Student Exam grade
Record Size 40
Table 11 Student_ExamSchedule

Exam
Primary Key: exam_id
Foreign Key: course_id
Field Names Data type Data Size Description
exam_id Text 20 Exam Id
exam_name Text 50 Exam name
exam_type Text 10 Exam Type
exam_fee Number 10 Exam Fee
course_id Text 10 Course Id
Record Size 100
Table 12 Exam

128
RepeatExamPayment
Primary Key: repeat_payment_id
Field Names Data type Data Size Description
repeat_payment_id Number 5 Repeat Payment Id
p_amount Number 10 Payment Amount
p_description Text 10 Payment Details
Record Size 25
Table 13 RepeatExamPayment

Student_ExamSchedule_RepeatExamPayment
Primary Keys: repeat_payment_id, user_id, exam_shedule_id
Foreign Keys: repeat_payment_id, user_id, exam_shedule_id
Field Names Data type Data Size Description
repeat_payment_id Number 5 Repeat Payment Id
user_id Text 10 Student’s Username
exam_shedule_id Text 20 Exam Schedule Id
p_date Date 10 Payment Date
Record Size 45
Table 14 Student_ExamSchedule_RepeatExamPayment

Exam_Schedule
Primary Key: exam_shedule_id
Foreign Keys: batch_id, exam_id
Field Names Data type Data Size Description
exam_shedule_id Text 20 Exam schedule Id
exam_name Text 30 Exam name
exam_type Text 30 Exam type
exam_start_time Time 5 Exam start date
exam_end_time Time 5 Exam end date
exam_date Date 10 Exam date
exam_status Text 20 Exam Status
batch_id Text 20 Batch Id
exam_id Text 20 Exam Id
Record Size 160
Table 15 Exam_Schedule

129
Course_Schedule
Primary Key: course_schedule_id
Foreign Key: batch_id

Field Names Data type Data Size Description


course_shedule_id Text 20 Course schedule Id
schedule_name Text 30 Schedule name
start_time Time 5 Course start time
end_time Time 5 Course end time
week_date Date 10 Course Dates
schedule_status Text 20 Course Schedule Status
batch_id Text 20 Batch Id
Record Size 110
Table 16 Course_Schedule

Student_CourseSchedule
Primary Keys: course_schedule_id, user_id
Foreign Keys: course_schedule_id, user_id
Field Names Data type Data Size Description
course_shedule_id Text 20 Course schedule Id
user_id Text 10 Student’s Username
time Time 5 Student attend time
attend_date Date 10 Student attend date
status Text 10 Student attendance status
Record Size 55
Table 17 Student_CourseSchedule

Feedback
Primary Key: feedback_id
Foreign Key: user_id
Field Names Data type Data Size Description
feedback_id Number 5 Feedback Id
feedback_rating Text 5 Feedback rating
feedback_comment Text 150 Feedback comment
feedback_date Date 10 Feedback timestamp
user_id Text 10 Student’s/ Teacher’s
Username
Record Size 180
Table 18 Feedback

130
Message
Primary Key: message_id
Foreign Key: user_id

Field Names Data type Data Size Description


message_id Number 10 Message Id
content Text 150 Message content
message_date Date 10 Message timestamp
user_id Text 10 Admin’s Username
Record Size 180
Table 19 Message

CourseWork
Primary Key: coursework_id
Foreign Keys: batch_id, user_id
Field Names Data type Data Size Description
coursework_id Number 5 Coursework Id
coursework_content Text 200 Coursework content
coursework_file Text 50 Coursework file
date Date 10 Coursework date
deadline Date 10 Coursework deadline
batch_id Text 20 Batch Id
user_id Text 10 Teacher’s Username
Record Size 305
Table 20 CourseWork

Student_CourseWork
Primary Keys: user_id, coursework_id
Foreign Keys: user_id, coursework_id

Field Names Data type Data Size Description


user_id Text 10 Student’s Username
coursework_id Number 5 Coursework number
uploaded_file Text 50 Student Coursework
uploaded file
uploaded_content Text 200 Student Coursework
uploaded content
coursework_grade Text 5 Coursework Grade
coursework_feedback Text 150 Coursework feedback
uploaded_date Date 10 Student Coursework
uploaded date
Record Size 430
Table 21 Student_CourseWork
131
User Mobile
Primary Keys: user_id, mobile
Foreign Key: user_id

Field Names Data type Data Size Description


user_id Text 10 User’s Username
mobile Number 10 User’s Mobile Number
Record Size 20
Table 22 User Mobile

Student Guardian Mobile


Primary Keys: user_id, guardian_mobile
Foreign Key: user_id

Field Names Data type Data Size Description


user_id Text 10 Student’s Username
guardian_mobile Number 10 Student’s Guardian
Mobile Number
Record Size 20
Table 23 Student Guardian Mobile

ExamSchedule Location
Primary Keys: exam_shedule_id, exam_location
Foreign Key: exam_shedule_id
Field Names Data type Data Size Description
exam_shedule_id Text 10 Exam schedule Id
exam_location Text 20 Exam Location
Record Size 30
Table 24 ExamSchedule Location

132

You might also like