Changeset 20031 for trunk/Mars/hawc/processing/find-calibration-files.sql
- Timestamp:
- 01/07/21 14:38:53 (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Mars/hawc/processing/find-calibration-files.sql
r20026 r20031 8 8 SELECT 9 9 -- NIGHT and RUNID of the data file 10 R1.NIGHT AS NIGHT, 11 R1.RUNID AS RUNID, 10 R1.Telescope AS Telescope, 11 R1.NIGHT AS NIGHT, 12 R1.RUNID AS RUNID, 12 13 -- NIGHT and RUNID of the DRS file 13 R2.NIGHT AS DrsNight,14 R2.RUNID AS DrsRunID,14 R2.NIGHT AS DrsNight, 15 R2.RUNID AS DrsRunID, 15 16 -- Time difference between the two 16 17 LEAST( … … 40 41 DoNotUse ON (R2.NIGHT=DoNotUse.NIGHT AND R2.RUNID=DoNotUse.RUNID) 41 42 WHERE 43 -- Of course claibration must be from the same telescope 44 R1.Telescope=R2.Telescope 45 AND 42 46 -- Select all combinations that have a data file in R1 and a drs file (at step 1) in R2 43 ISNULL(R1.DRSSTEP) AND R2.DRSSTEP=1 47 ISNULL(R1.DRSSTEP) AND R2.DRSSTEP=1 44 48 AND 45 49 -- Only DRS files with 100 events and the correct ROI are considered … … 51 55 -- AND ABS(UNIX_TIMESTAMP(R2.`DATE-OBS`)-UNIX_TIMESTAMP(R1.`DATE-OBS`))<78*3600 52 56 ORDER BY 53 R1.NIGHT, R1.RUNID, DeltaT 57 R1.Telescope, 58 R1.NIGHT, 59 R1.RUNID, 60 DeltaT 54 61 ) 55 62 SELECT 63 Telescope, 56 64 NIGHT, 57 65 RUNID,
Note:
See TracChangeset
for help on using the changeset viewer.