Changeset 37917 for trunk/ippToPsps/jython/diffbatch.py
- Timestamp:
- Feb 20, 2015, 1:19:35 PM (11 years ago)
- File:
-
- 1 edited
-
trunk/ippToPsps/jython/diffbatch.py (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippToPsps/jython/diffbatch.py
r37763 r37917 327 327 self.logger.infoPair("need to cull"," nulls objid") 328 328 results= self.scratchDb.reportAndDeleteRowsWithNULLS("DiffDetection", "diffObjID") 329 self.logger.infoPair("Adding 'row' columns to", "DiffDetection tables") 330 # diff has a primary key, so use this instead 331 self.scratchDb.addRowCountColumnNoKey("DiffDetection", "row") 329 332 self.logger.infoPair("adding","uniquePSPSDFid") 330 333 self.updatePspsUniqueIDs("DiffDetection") 334 self.logger.infoPair("Dropping row column from", "DiffDetection table") 335 self.scratchDb.dropColumn("DiffDetection", "row") 336 331 337 332 338 ''' … … 424 430 425 431 def updatePspsUniqueIDs(self,table): 426 sql = "UPDATE "+table+" join (select @r:=@r+1 rownum, diffobjID from \ 427 (select @r:=0) r, "+table+" t) as foo using (diffobjID) set \ 428 uniquePspsDFid = ((" +str(self.batchID)+ "*1000000000 ) + rownum)" 432 #sql = "UPDATE "+table+" join (select @r:=@r+1 rownum, diffobjID from \ 433 #(select @r:=0) r, "+table+" t) as foo using (diffobjID) set \ 434 #uniquePspsDFid = ((" +str(self.batchID)+ "*1000000000 ) + rownum)" 435 sql = "UPDATE DiffDetection set uniquePspsDFid = (("+str(self.batchID)+"*1000000000 ) + row)" 429 436 try: self.scratchDb.execute(sql) 430 437 except:
Note:
See TracChangeset
for help on using the changeset viewer.
