Index: trunk/ippToPsps/jython/detectionbatch.py
===================================================================
--- trunk/ippToPsps/jython/detectionbatch.py	(revision 38839)
+++ trunk/ippToPsps/jython/detectionbatch.py	(revision 38841)
@@ -680,14 +680,14 @@
                 if x==7 and y==7: continue
 
-                ota = "XY%d%d" % (x, y)
-                extension = ota + "_psf"
-                if extension not in self.tablesLoaded: continue
-
-                self.scratchDb.createIndex(extension, "IPP_IDET")
-
-        extension = "Chip_psf"
-        if extension in self.tablesLoaded:
-            # try the test Chip
-            self.scratchDb.createIndex(extension, "IPP_IDET")
+                cmfTable = "XY%d%d.psf" % (x, y)
+                mysTable = "XY%d%d_psf" % (x, y)
+                if cmfTable not in self.tablesLoaded: continue
+
+                self.scratchDb.createIndex(mysTable, "IPP_IDET")
+
+        cmfTable = "XY%d%d.psf" % (x, y)
+        mysTable = "XY%d%d_psf" % (x, y)
+        if cmfTable in self.tablesLoaded: 
+            self.scratchDb.createIndex(mysTable, "IPP_IDET")
 
         self.logger.infoPair("created indexes on", "IPP tables")      
@@ -860,4 +860,9 @@
     def populatePspsTables(self):
 
+        print "********** ***************"
+        for table in self.tablesLoaded:
+            print "table: " + str(table)
+        print "--------------------------"
+
         # loop through all OTAs again to update with DVO IDs
         self.skipBatch = False
@@ -882,5 +887,5 @@
 
                 ota = "XY%d%d" % (x, y)
-                extension = ota + "_psf"
+                extension = ota + ".psf"
                 if extension not in self.tablesLoaded: continue
 
@@ -893,5 +898,5 @@
 
 
-        extension = "Chip_psf"
+        extension = "Chip.psf"
         if extension in self.tablesLoaded:
             if self.populatePspsTablesChip("Chip", 0, 0, results, tables): otaCount = otaCount + 1
