2020-06 s dispo table cleanup
|The following query was used. It takes a good long while to run. Don't even try it without filtering for a specific unit first.|
SELECT s_dispo.location_name, s_dispo.active, s_locations_allowed_collection.Laptop_identifier, Count(pa.D_ID) AS pa, Count(p.D_ID) AS p, Count(sl.D_ID) AS sl, Count(d.D_ID) AS d, sl.RecordStatus FROM ((((s_dispo LEFT JOIN s_locations_allowed_collection ON s_dispo.location_name = s_locations_allowed_collection.ServiceLocation) LEFT JOIN L_Log AS sl ON s_dispo.dispo_ID = sl.Service_Location) LEFT JOIN L_Log AS p ON s_dispo.dispo_ID = p.Previous_Location) LEFT JOIN L_Log AS d ON s_dispo.dispo_ID = d.Dispo) LEFT JOIN L_Log AS pa ON s_dispo.dispo_ID = pa.Pre_admit_Inpatient_Institution WHERE (((s_dispo.s_location)=True)) GROUP BY s_dispo.location_name, s_dispo.active, s_locations_allowed_collection.Laptop_identifier, sl.RecordStatus;
entries with s_location = true but no entry in allowed table
The following had entries in S dispo table with s_location = true, but no corresponding entry in the allowed table. This means they were not available to enter.
- STB_B5a - 0 entries, deleted
- STB_E5a - 1 entry, STB_E5a-880
Records that had been added but were never used
Some of these were added during covid move confusion.
The following records had no corresponding entries at all. They were entirely deleted from the table:
older, not part of covid move confusion
added for workload sharing at some point, but not used, and no longer needed now:
changes in preparation for no longer using letter ending entries for workload sharing
- HSC_H7 - no entries with this as Service/Location and not allowed, but has dispo entries, changed to be s_location = false