IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Oct 9, 2013, 4:53:45 PM (13 years ago)
Author:
heather
Message:

added feature of time range for P2/ST - doesnt work for ST yet, queue those seperately

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ippToPsps/jython/gpc1db.py

    r35994 r36201  
    4949    NB this uses Bill's potentially temporary 'skycells' database when finding RA/Dec for stacks.
    5050    '''
    51     def getItemsInThisDVODbForThisStage(self, dvoDb, batchType, minRA=-999, maxRA=999, minDec=-999, maxDec=999):
     51    def getItemsInThisDVODbForThisStage(self, dvoDb, batchType, minRA=-999, maxRA=999, minDec=-999, maxDec=999, tstart="0000-00-00 00:00:00", tend = "0000-00-00 00:00:00"):
    5252
    5353        self.logger.debugPair("GPC1 RA range", "%.2f -> %.2f" % (minRA, maxRA))
    5454        self.logger.debugPair("GPC1 Dec range", "%.2f -> %.2f" % (minDec, maxDec))
    55 
     55       
    5656        rows = []
    5757
     
    8080                   AND addRun.state = 'full' \
    8181                   AND decl BETWEEN RADIANS(" + str(minDec) + ") AND RADIANS(" + str(maxDec) + ") \
    82                    AND ra BETWEEN RADIANS(" + str(minRA) + ") AND RADIANS(" + str(maxRA) + ")"
     82                   AND ra BETWEEN RADIANS(" + str(minRA) + ") AND RADIANS(" + str(maxRA) + ") \
     83                   AND dateobs >= '" + tstart + "'\
     84                   AND dateobs <= '" + tend  + "'"
    8385
    8486        elif batchType == "ST":       
Note: See TracChangeset for help on using the changeset viewer.