Changeset 32654
- Timestamp:
- Nov 10, 2011, 3:59:12 PM (15 years ago)
- File:
-
- 1 edited
-
trunk/ippToPsps/jython/ipptopspsdb.py (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippToPsps/jython/ipptopspsdb.py
r32580 r32654 125 125 126 126 self.logger.debug("Found %d processed but-not-on-datastore items" % len(ids)) 127 128 return ids129 130 '''131 Returns a list of processed batch IDs that either not yet loaded to the ODM or not merge_worthy or not merged132 NOTE we exclude batches already deleted from the datastore, as sometimes we delete stuff prior to loading to ODM if there is a known problem with the batch133 '''134 def getAllUnfinishedBatchIDs(self, epoch, dvoGpc1Label, batchType):135 136 sql = "SELECT batch_id \137 FROM batch \138 WHERE timestamp > '" + epoch + "' \139 AND dvo_db = '" + dvoGpc1Label + "' \140 AND loaded_to_datastore = 1 \141 AND batch_type = '" + batchType + "' \142 AND deleted_datastore = 0 \143 AND loaded_to_ODM != -1 \144 AND merge_worthy != -1 \145 AND merged = 0"146 147 ids = []148 try:149 rs = self.executeQuery(sql)150 while (rs.next()):151 ids.append(rs.getInt(1))152 except:153 self.logger.exception("Can't query for unloaded batch ids in ipptopsps Db")154 155 rs.close()156 157 self.logger.debug("Found %d unloaded items" % len(ids))158 127 159 128 return ids
Note:
See TracChangeset
for help on using the changeset viewer.
