I need help with a broken report... I customized the "todaysAtttSummary.html" page because I needed the Home room and bus # to show up... plus I need to avoid showing a specific Attendance code for present that I added, i thought I handled that in the WHERE clause.. this is what I have:
------------------------------
~[tlist_sql;
SELECT s.DCID sDCID, s.LastFirst student, s.Grade_Level, s.Home_Room hr, s.ambus bu, sch.Abbreviation school, t.att_code, t.description,
(SELECT count(att_date) FROM attendance WHERE attendance_codeID = t.attendance_codeID AND yearID = t.yearID AND studentID = t.studentID AND att_mode_code = 'ATT_ModeDaily') ytdCode,
(SELECT count(att_date) FROM attendance att INNER JOIN Attendance_Code attc ON att.attendance_codeID = attc.ID WHERE Presence_Status_CD = 'Absent' AND att.yearID = t.yearID AND studentID = t.studentID AND att_mode_code = 'ATT_ModeDaily') ytdAbs,
(SELECT count(att_date) FROM attendance att INNER JOIN Att_Code_Code_Entity acce ON att.attendance_codeID = acce.attendance_codeID INNER JOIN Code_Entity ce ON ce.ID = acce.Code_EntityID WHERE UPPER(ce.CE_Entity) = 'ATT_ATTCODEENTITY' AND UPPER(ce.CE_Code) = 'TARDY' AND att.yearID = t.yearID AND att.studentID = t.studentID AND att.att_mode_code = 'ATT_ModeDaily') ytdTar,
t.att_comment
FROM (
SELECT att.studentID, att.yearID, att.schoolID, att.attendance_codeID, attc.att_code, attc.description, att.att_comment
FROM Attendance att
INNER JOIN Attendance_Code attc ON att.attendance_codeID = attc.ID
WHERE att.att_date = 07/05/2012
AND att.att_mode_code = 'ATT_ModeDaily'
AND att.attendance_codeID <> 1216
AND att.schoolID LIKE CASE WHEN ~(curschoolid) = 0 THEN '%' ELSE to_char(~(curschoolid)) END
)t
INNER JOIN Students s ON t.studentID = s.ID
INNER JOIN Schools sch ON s.Enrollment_SchoolID = sch.School_Number
ORDER BY student;alternatecolor]
<tr class="oddrow">
<td>~(count;-)</td>
<td><a href="/admin/students/home.html?frn=001~(sDCID;l)" target="_blank">~(student;t)</a></td>
<td style="text-align:center;">~(grade;l)</td>
<td>~(sch;t)</td>
<td>~(hr)</td>
<td>~(bu)</td>
<td>(~(ac;t)) ~(desc;t)</td>
<td style="text-align:center;">~(ytdCode;l)</td>
<td style="text-align:center;">~(ytdAbs;l)</td>
<td style="text-align:center;">~(ytdTar;l)</td>
<td>~(Att_Comment;t) </td>
</tr>
[/tlist_sql]
--------------------------------------
ANY HELP WOULD be great!!!!!
tvernaci
Fri, 11/04/2022 - 6:35pm
Permalink
Figured out?
Did you figure this out? We would like to see homeroom data in our reports too!
Anthony J. Vernaci III