i am e newbie programmer and i want to improve a "student program" for schools. In the program i want to add lesson information. For example:
Student X
Lesson name 1st exam 2nd exam 3rdexam
mathematics 80 70 80
history 70 70 70
...
I have a database that called KFS with three tables.
Identity
RecordID | firstname | lastname | address | city
Lesson
LessonID | name | description
Lessondetail
DataID | RecordID | LessonID | lessonname | firstpoint | secondpoint | thirdpoint
I can already show list of students in a GridView, but I also want to show the selected student's points.
Is my database enough for this application? If yes, how can i design that relationship and show in gridview? Or should i modify my database?
I'll second Dan Diplo's advice about normalizing
LessonDetail
if it's not certain that you'll always have 3 exams. Unfortunately, that requires a pivot to get your data in the format you want - but that's another question. Also, you haveLessonName
inLessonDetail
- but it should be pulled fromLesson
instead.The ASP.NET side is fairly easy - it's just a standard Master/Details view: