Index: trunk/ippToPsps/jython/objectbatch.py
===================================================================
--- trunk/ippToPsps/jython/objectbatch.py	(revision 34290)
+++ trunk/ippToPsps/jython/objectbatch.py	(revision 34441)
@@ -124,9 +124,10 @@
                    ," + filter[1] + "StackPSFFlux = FLUX_PSF \
                    ," + filter[1] + "StackPSFFluxErr = FLUX_PSF_ERR \
-                   ," + filter[1] + "StackKronMag = -2.5 * log10(FLUX_KRON) -8.9 \
+                   ," + filter[1] + "StackKronMag = -2.5 * log10(FLUX_KRON) + 8.9 \
                    ," + filter[1] + "StackKronMagErr = FLUX_KRON_ERR / FLUX_KRON \
                    ," + filter[1] + "20pct = MAG_20/1000 \
                    ," + filter[1] + "80pct = MAG_80/1000 \
-                   "
+                   ," + filter[1] + "Flags = FLAGS "  
+                   
             
             self.scratchDb.execute(sql)
@@ -141,4 +142,20 @@
                    WHERE " + filter[1] + "MeanPSFMagErr > " + str(cut)
             self.scratchDb.execute(sql)
+
+        self.logger.infoPair("Setting to NULL all x20pct =", "32.767" ) 
+        for filter in filters:
+            sql  = "UPDATE Object \
+                   SET " + filter[1] + "20pct = null \
+                   WHERE " + filter[1] + "20pct > 32.766"
+            self.scratchDb.execute(sql)
+        self.logger.infoPair("Setting to NULL all x80pct =", "32.767" )
+        for filter in filters:
+            sql  = "UPDATE Object \
+                    SET " + filter[1] + "80pct = null \
+                    WHERE " + filter[1] + "80pct > 32.766"
+            self.scratchDb.execute(sql)
+
+
+
 
     '''
@@ -187,4 +204,6 @@
                ,decErr \
                ,nDetections \
+               ,extra \
+               ,sgSep \
                ,dataRelease \
                ) \
@@ -200,4 +219,6 @@
                ,DEC_ERR \
                ,NMEASURE \
+               ,PSF_QF_PERF \
+               ,STARGAL_SEP \
                , " + str(self.config.dataRelease) + "\
                FROM " + cptTableName
