Hi,

Thanks for your comments.

In this table the entries would look like this:

student_id      hour_of_day     day_of_week     week_of_course    

1               1                       1               1
6               1                       1               1
14              1                       1               1

Thus the table will have as many identical rows except in one column as there are 
absentees in particular session. My doubt is isnt it reduntant and is there any other 
ways of doing things without this redundancy?

I am newbie to databases (just a few weeks)

Suresh

On Fri, Feb 09, 2001 at 09:26:49AM -0000, Russell King wrote:
> From: Suresh Kumar R <[EMAIL PROTECTED]>
> 
> > I want to have the absentee list of students per hour_of_day
> per day for a week, done for the entire course.
> >
> > One possibility I thought was to create a table with date and
> each hour of the day as columns, then each cell would have to
> have variable number of student roll nos who are absent for that
> particular hour and I dont know how I can enter an array of
> numnbers.
> 
> I think the best method to deal with this is just have a single
> table containing :
> 
> student_id    int
> hour_of_day    int
> day_of_week    int
> week_of_course    int
> 
> One assumes a student is present for all classes.
> 
> If a student is absent, an entry is made in the table, recording
> the student's number, and the time/day/week they are absent.
> 
> It is more elegant to record the date using a date field, but it
> will complicate your subsequent select queries, so I would use
> the above design in your case.
> 
> This has the added advantage of only storing data by exception.
> 
> Russ.
> 
> 

----------------------------------------------------------------------
Suresh Kumar.R,  
Dept of Electronics & Communication
College of Engineering, Trivandrum - 695 016, INDIA
Phone: (O) 91 471 595634

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to