Updates to school_year in Machine_Archive_Upgrades /*Update Machine_Archive_Upgrades SET school_year = 16 WHERE school_year is null and org_id_ma = 65 AND BDate = '2015-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 16 WHERE school_year is null and org_id_ma = 52 and BDate = '2015-11-20 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 17 WHERE school_year is null and org_id_ma = 1 and BDate = '2016-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 20 WHERE school_year is null and org_id_ma = 4 and BDate = '2019-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 18 WHERE school_year is null and org_id_ma = 5 and BDate = '2017-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 17 WHERE school_year is null and org_id_ma = 6 and BDate = '2016-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 18 WHERE school_year is null and org_id_ma = 8 and BDate = '2017-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 17 WHERE school_year is null and org_id_ma = 12 and BDate = '2016-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 21 WHERE school_year is null and org_id_ma = 12 and BDate = '2020-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 16 WHERE school_year is null and org_id_ma = 35 and BDate = '2015-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 21 WHERE school_year is null and org_id_ma = 35 and BDate = '2020-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 20 WHERE school_year is null and org_id_ma = 39 and BDate = '2019-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 19 WHERE school_year is null and org_id_ma = 48 and BDate = '2018-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 17 WHERE school_year is null and org_id_ma = 51 and BDate = '2016-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 19 WHERE school_year is null and org_id_ma = 54 and BDate = '2018-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 21 WHERE school_year is null and org_id_ma = 55 and BDate = '2020-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 17 WHERE school_year is null and org_id_ma = 56 and BDate = '2016-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 18 WHERE school_year is null and org_id_ma = 57 and BDate = '2017-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 18 WHERE school_year is null and org_id_ma = 58 and BDate = '2017-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 21 WHERE school_year is null and org_id_ma = 59 and BDate = '2020-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 18 WHERE school_year is null and org_id_ma = 60 and BDate = '2017-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 18 WHERE school_year is null and org_id_ma = 61 and BDate = '2017-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 21 WHERE school_year is null and org_id_ma = 65 and BDate = '2020-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 19 WHERE school_year is null and org_id_ma = 77 and BDate = '2018-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 17 WHERE school_year is null and org_id_ma = 83 and BDate = '2016-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 21 WHERE school_year is null and org_id_ma = 83 and BDate = '2020-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 18 WHERE school_year is null and org_id_ma = 84 and BDate = '2017-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 21 WHERE school_year is null and org_id_ma = 83 and BDate = '2020-08-12 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 18 WHERE school_year is null and org_id_ma = 87 and BDate = '2017-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 19 WHERE school_year is null and org_id_ma = 91 and BDate = '2018-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 21 WHERE school_year is null and org_id_ma = 93 and BDate = '2020-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 17 WHERE school_year is null and org_id_ma = 97 and BDate = '2016-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 21 WHERE school_year is null and org_id_ma = 97 and BDate = '2020-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 21 WHERE school_year is null and org_id_ma = 97 and BDate = '2020-08-12 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 18 WHERE school_year is null and org_id_ma = 96 and BDate = '2017-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 21 WHERE school_year is null and org_id_ma = 1852 and BDate = '2020-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 21 WHERE school_year is null and org_id_ma = 12 and BDate = '2020-09-03 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 16 WHERE school_year is null and org_id_ma = 55 and BDate = '2015-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 16 WHERE school_year is null and org_id_ma = 52 and BDate = '2015-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 20 WHERE school_year is null and org_id_ma = 99 and BDate = '2019-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 17 WHERE school_year is null and org_id_ma = 112 and BDate = '2016-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 19 WHERE school_year is null and org_id_ma = 113 and BDate = '2018-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 19 WHERE school_year is null and org_id_ma = 1769 and BDate = '2018-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 20 WHERE school_year is null and org_id_ma = 1781 and BDate = '2019-07-01 00:00:00'; Update Machine_Archive_Upgrades SET school_year = 20 WHERE school_year is null and org_id_ma = 1838 and BDate = '2019-07-01 00:00:00';*/ SELECT * FROM Machine_Archive_Upgrades WHERE school_year is null AND SerialNumber is null and org_id_ma is null; #12 rows