Issue

The Create Substitute Teacher Accounts page lists Teachers who are no longer teaching. It also lists Classified Staff that are not teachers.


Cause

The Create Substitute Teachers page will display Teachers who have a record for the current school in ATR (Supp Att Staff), STA (Staff Assignments), STJ (Staff Job Assignments), or TCH (Teachers). It will also display Classified Staff if the Staff record has an STA record (Staff Assignments). 


Resolution

These queries can be used to find if there are any records in the ATR, STA, STJ, or TCH tables for a particular Staff record. Replace the XXXX with the actual Staff ID number:

LIST ATR SC SE ID IF ID = XXXX 

LIST STA ID SCL SD ED IF ID = XXXX 

LIST STJ ID SCL SD ED IF STJ.ID = XXXX 

LIST TCH SC TN ID TG IF ID = XXXX 



Note: If the user has SQL access, this SQL script can help find records in ATR, STA, STJ, and TCH that are tied to any inactive STF record: 
SELECT 'ATR' 'Table', SC, ID, CONCAT('Session # ',SE) [Additional Info] FROM ATR WHERE DEL = 0 AND SC <> 0 AND ID IN (SELECT ID FROM STF WHERE TG <> '') UNION ALL
SELECT 'STA' 'Table', SCL, ID, '' [Additional Info] FROM STA WHERE DEL = 0 AND SCL <> 0 AND ID IN (SELECT ID FROM STF WHERE TG <> '') UNION ALL
SELECT 'STJ' 'Table', SCL, ID, '' [Additional Info] FROM STJ WHERE DEL = 0 AND SCL <> 0 AND ID IN (SELECT ID FROM STF WHERE TG <> '') UNION ALL
SELECT 'TCH' 'Table', SC, ID, CONCAT('Teacher # ',TN) [Additional Info] FROM TCH WHERE DEL = 0 AND SC <> 0 AND ID IN (SELECT ID FROM STF WHERE TG <> '') 
ORDER BY ID, 'Table'

These can also be run one table at a time by removing UNION ALL from the statement


Once the ATR, STA, STJ, or TCH records are deleted, the Staff member will no longer appear on the Create Substitute Teacher Accounts page.