Changeset 24427 for branches/pap_mops/ippTools/share/pubtool_pending.sql
- Timestamp:
- Jun 15, 2009, 5:28:09 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/pap_mops/ippTools/share/pubtool_pending.sql
r24392 r24427 1 1 SELECT 2 publishRun.pub_id, 3 publishRun.stage_id, 4 publishClient.destination, 5 publishClient.stage, 6 publishClient.format, 7 publishToDo.component 8 FROM publishRun 9 JOIN publishClient USING(client_id) 10 JOIN (( 2 publishToDo.* 3 FROM (( 11 4 SELECT 12 pub_id, 13 diff_id AS stage_id, 14 skycell_id AS component 5 publishRun.pub_id, 6 publishClient.product, 7 publishClient.stage, 8 diffRun.diff_id AS stage_id, 9 publishRun.workdir 15 10 FROM publishRun 16 11 JOIN publishClient USING(client_id) … … 19 14 JOIN diffSkyfile USING(diff_id) 20 15 WHERE publishClient.stage = 'diff' 16 AND publishRun.state = 'new' 17 AND diffRun.state = 'full' 21 18 ) AS publishDiffs UNION ( 22 19 SELECT 23 pub_id, 24 cam_id AS stage_id, 25 NULL AS component 20 publishRun.pub_id, 21 publishClient.product, 22 publishClient.stage, 23 camRun.cam_id AS stage_id, 24 publishRun.workdir 26 25 FROM publishRun 27 26 JOIN publishClient USING(client_id) … … 29 28 ON camRun.cam_id = publishRun.stage_id 30 29 WHERE publishClient.stage = 'camera' 30 AND publishRun.state ='new' 31 AND camRun.state = 'full' 31 32 ) AS publishCams 32 ) AS publishToDo USING(pub_id, stage_id) 33 LEFT JOIN publishFile USING(pub_id, component) 34 WHERE publishRun.state = 'new' 35 AND publishFile.pub_id IS NULL 33 ) AS publishToDo 34 LEFT JOIN publishDone USING(pub_id) 35 WHERE publishDone.pub_id IS NULL
Note:
See TracChangeset
for help on using the changeset viewer.
