Changeset 18609 for trunk/ippTools/share/stacktool_definebyquery_test.sql
- Timestamp:
- Jul 17, 2008, 4:12:41 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippTools/share/stacktool_definebyquery_test.sql
r18579 r18609 11 11 -- stacktool_definebyquery_part1.sql 12 12 SELECT 13 * 13 skycell_id, 14 tess_id, 15 filter, 16 num_warp, 17 MAX(num_stack) AS num_stack 14 18 FROM (( 15 19 -- Number of stack-ready warps as a function of skycell and filter … … 30 34 AND warpSkyfile.fault = 0 31 35 -- Any additional selection on warps/exposures goes here 32 33 36 -- stacktool_definebyquery_part2.sql 34 37 GROUP BY … … 42 45 tess_id, 43 46 filter, 44 stack_id,45 47 COUNT(stackInputSkyfile.warp_id) as num_stack -- number of warps in a stack 46 48 FROM stackRun … … 48 50 GROUP BY 49 51 stack_id 50 -- This ORDER BY is important: it sets the final num_stack that51 -- comes out of the top-level GROUP BY. We want it to be the52 -- biggest number for a skycell/filter combination.53 ORDER BY54 num_stack DESC55 52 ) AS stackSizes 56 53 -- JOINing the warpsToStack and stackSizes tables
Note:
See TracChangeset
for help on using the changeset viewer.
