Index: branches/eam_branches/ipp-20121219/ippToPsps/config/settings.xml
===================================================================
--- branches/eam_branches/ipp-20121219/ippToPsps/config/settings.xml	(revision 35055)
+++ branches/eam_branches/ipp-20121219/ippToPsps/config/settings.xml	(revision 35056)
@@ -18,14 +18,14 @@
   <!-- GPC1 Db section -->
   <gpc1database>
-    <!-- TEST VERSION
+    <!-- TEST VERSION -->
     <name>gpc1test</name>
     <host>localhost</host>
     <user>dvo</user>
-    <password>dvo</password> -->
-    <!-- REAL VERSION -->
+    <password>dvo</password>
+    <!-- REAL VERSION
     <name>gpc1</name>
     <host>ippdb01</host>
     <user>ipp</user>
-    <password>ipp</password>
+    <password>ipp</password> -->
   </gpc1database>
 
Index: branches/eam_branches/ipp-20121219/ippToPsps/jython/batch.py
===================================================================
--- branches/eam_branches/ipp-20121219/ippToPsps/jython/batch.py	(revision 35055)
+++ branches/eam_branches/ipp-20121219/ippToPsps/jython/batch.py	(revision 35056)
@@ -543,5 +543,6 @@
             raise
 
-        # this reads the detection tables from the CMF/SMF file(s)
+        # for P2/ST, this reads the detection tables from the CMF/SMF file(s)
+        # for OB, this imports object data from DVO
         if not self.importIppTables():
             self.logger.errorPair("Aborting this batch", "could not import IPP tables")
Index: branches/eam_branches/ipp-20121219/ippToPsps/jython/dvoobjects.py
===================================================================
--- branches/eam_branches/ipp-20121219/ippToPsps/jython/dvoobjects.py	(revision 35055)
+++ branches/eam_branches/ipp-20121219/ippToPsps/jython/dvoobjects.py	(revision 35056)
@@ -8,4 +8,5 @@
 import logging
 import glob
+from subprocess import call, PIPE, Popen
 
 from dvo import Dvo
@@ -47,2 +48,29 @@
 
 
+    '''
+    ingest object data into MySQL database using the native DVO program dvopsps
+    Populates dvoDetections and dvoDone with FITS tables from DVO for the defined sky area, this
+    includes purging detections outside sky area
+    '''
+    def nativeIngestRegion(self, region):
+
+        # drop cpt/cps/object table?
+        # create detections table?
+
+        # TODO path to DVO prog hardcoded temporarily
+        cmd = "dvopsps objects"
+        cmd += " -dbhost " + self.scratchDb.dbHost
+        cmd += " -dbname " + self.scratchDb.dbName
+        cmd += " -dbuser " + self.scratchDb.dbUser
+        cmd += " -dbpass " + self.scratchDb.dbPass
+        cmd += " -D CATDIR " + self.config.dvoLocation
+        cmd += " -cpt " + region
+
+        self.logger.infoPair("Running dvopsps", cmd)
+        p = Popen(cmd, shell=True, stdout=PIPE)
+        p.wait()
+
+        # update lists after attempted sync
+        # self.printSummary()
+
+        return True
Index: branches/eam_branches/ipp-20121219/ippToPsps/jython/loader.py
===================================================================
--- branches/eam_branches/ipp-20121219/ippToPsps/jython/loader.py	(revision 35055)
+++ branches/eam_branches/ipp-20121219/ippToPsps/jython/loader.py	(revision 35056)
@@ -190,4 +190,7 @@
                                 useFullTables = 1
                         else:
+                            # XXX EAM : this is not currently an
+                            # option. either remove the non-native
+                            # ingest code or make it an option
                             # if we are using the native loader, always use it
                             # need to work out a good boundary / region strategy in coordination with 
@@ -196,4 +199,11 @@
                             useFullTables = 1
                 
+                    ## else:
+                    ##     # if we are using the native loader, always use it
+                    ##     # need to work out a good boundary / region strategy in coordination with 
+                    ##     # impact of mysql insertion
+                    ##     self.dvoObjects.nativeIngestObjects(boxDim['RA'], boxDim['DEC'], boxSizeSansBorder)
+                    ##     useFullTables = 1
+
                     '''
                     NOTE EAM : "TheseItems" refers to each of the stack CMFs, camera SMFs, or object batches
Index: branches/eam_branches/ipp-20121219/ippToPsps/jython/objectbatch.py
===================================================================
--- branches/eam_branches/ipp-20121219/ippToPsps/jython/objectbatch.py	(revision 35055)
+++ branches/eam_branches/ipp-20121219/ippToPsps/jython/objectbatch.py	(revision 35056)
@@ -71,5 +71,8 @@
         self.region = self.scratchDb.getRegionNameFromThisDvoIndex(self.id)
         self.ippToPspsDb.insertObjectMeta(self.batchID, self.region)
-        self.dvoObjects.ingestRegion(self.region)
+        if True:
+            self.dvoObjects.nativeIngestRegion(self.region)
+        else:
+            self.dvoObjects.ingestRegion(self.region)
 
         return True
Index: branches/eam_branches/ipp-20121219/ippToPsps/jython/stackbatch.py
===================================================================
--- branches/eam_branches/ipp-20121219/ippToPsps/jython/stackbatch.py	(revision 35055)
+++ branches/eam_branches/ipp-20121219/ippToPsps/jython/stackbatch.py	(revision 35056)
@@ -714,4 +714,6 @@
     '''    
     Populates the StackDetectionCalib table
+    XXX this can probably get a big speed increase by using 'SELECT () INTO OUTFILE '/tmp/name' and then
+    calling the load data infile '/tmp/name' into table;
     '''
     def populateStackDetectionCalib(self):
