IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Oct 28, 2015, 8:29:33 PM (11 years ago)
Author:
eugene
Message:

add -stilts option; fix stilts and regex for detectionbatch; add tableprefix option for stacks; alter photcode.type to type_as_int

File:
1 edited

Legend:

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

    r38990 r38995  
    590590    '''
    591591    def importPhotcodes(self, path, tableName):
    592         if True:
     592        if self.config.useOhanaMYSQLtoFITS:
    593593            self.importPhotcodesOhana(path,tableName)
    594594        else:
     
    607607      # table = stilts.tpipe(table, cmd='addcol -after TYPE TYPE_AS_INT "TYPE + 0"')
    608608
    609       self.scratchDb.loadFITStoMYSQL (path, tableName)
     609      self.scratchDb.loadFITStoMYSQL (path, "-tablename " + tableName)
     610
     611      sql = "ALTER TABLE " + tableName + " ADD COLUMN TYPE_AS_INT INT AFTER TYPE"
     612      self.scratchDb.execute(sql)
     613
     614      sql = "UPDATE " + tableName + " SET TYPE_AS_INT = ascii(TYPE)"
     615      self.scratchDb.execute(sql)
    610616
    611617      self.logger.debugPair("Finished importing", tableName)
Note: See TracChangeset for help on using the changeset viewer.