July 11, 2012 at 2:23 am
hi friends i am new to sql i have a table with fields
Table=ATTENDANCE
Attenid studentid teacherid repleceteacherid currentdat classid
1 1 1 0 6/7/2012 1
2 2 0 2 7/7/2012 1
3 1 1 0 8/7/2012 1
now i want to calculate teacher attendance between 2 dates each teacher is assigned to one class when teacher takes his class then his teacherid is get inserted to teacherid col(with replacement=0)
and when other techer takes the class then his teacherid get inserted in replacementteacher col(with teacherid=0)
i want the output in the following form
totallectures presentlectures absentlectures
10 7 3
how to write query if possible send me the query
please help
July 11, 2012 at 6:57 am
Is this a homework assignment?
Viewing 2 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply