Index: trunk/ippTools/share/difftool_pendingcleanupskyfile.sql
===================================================================
--- trunk/ippTools/share/difftool_pendingcleanupskyfile.sql	(revision 30539)
+++ trunk/ippTools/share/difftool_pendingcleanupskyfile.sql	(revision 30544)
@@ -9,5 +9,5 @@
     USING(diff_id)
 WHERE
-   ((diffRun.state = 'goto_cleaned'  AND diffSkyfile.data_state = 'full')
+   ((diffRun.state = 'goto_cleaned'  AND (diffSkyfile.data_state = 'full' OR diffSkyfile.data_state = 'update'))
     OR
     (diffRun.state = 'goto_scrubbed' AND diffSkyfile.data_state != 'scrubbed')
Index: trunk/ippTools/share/difftool_setskyfiletoupdate.sql
===================================================================
--- trunk/ippTools/share/difftool_setskyfiletoupdate.sql	(revision 30539)
+++ trunk/ippTools/share/difftool_setskyfiletoupdate.sql	(revision 30544)
@@ -1,11 +1,9 @@
 UPDATE diffRun
     JOIN diffSkyfile USING(diff_id)
-    LEFT JOIN magicDSRun ON (stage_id = diff_id AND stage = 'diff')
-    LEFT JOIN magicDSFile ON (magicDSRun.magic_ds_id = magicDSFile.magic_ds_id
-                              AND component = skycell_id)
 SET diffRun.state = 'update', 
-    diffSkyfile.data_state = 'update'
+    diffSkyfile.data_state = 'update',
+    diffSkyfile.fault = 0
     -- set hook %s
 WHERE diff_id = %lld
     AND (diffRun.state = 'cleaned' OR diffRun.state = 'update')
-    AND (diffSkyfile.data_state = 'cleaned')
+    AND (diffSkyfile.data_state = 'cleaned' AND diffSkyfile.data_state = 'update')
Index: trunk/ippTools/share/magicdstool_setfiletoupdate.sql
===================================================================
--- trunk/ippTools/share/magicdstool_setfiletoupdate.sql	(revision 30539)
+++ trunk/ippTools/share/magicdstool_setfiletoupdate.sql	(revision 30544)
@@ -7,3 +7,3 @@
 WHERE magic_ds_id = %lld
     AND (magicDSRun.state = 'cleaned' OR magicDSRun.state = 'update')
-    AND (magicDSFile.data_state = 'cleaned')
+    AND (magicDSFile.data_state = 'cleaned' OR magicDSFile.data_state ='update')
Index: trunk/ippTools/share/warptool_setskyfiletoupdate.sql
===================================================================
--- trunk/ippTools/share/warptool_setskyfiletoupdate.sql	(revision 30539)
+++ trunk/ippTools/share/warptool_setskyfiletoupdate.sql	(revision 30544)
@@ -1,11 +1,9 @@
 UPDATE warpRun
     JOIN warpSkyfile USING(warp_id)
-    LEFT JOIN magicDSRun ON (stage_id = warp_id AND stage = 'warp')
-    LEFT JOIN magicDSFile ON (magicDSRun.magic_ds_id = magicDSFile.magic_ds_id
-                              AND component = skycell_id)
 SET warpRun.state = 'update', 
-    warpSkyfile.data_state = 'update'
+    warpSkyfile.data_state = 'update',
+    warpSkyfile.fault = 0
     -- set hook %s
 WHERE warp_id = %lld
     AND (warpRun.state = 'cleaned' OR warpRun.state = 'update')
-    AND (warpSkyfile.data_state = 'cleaned')
+    AND (warpSkyfile.data_state = 'cleaned' OR warpSkyfile.data_state = 'update')
