Index: /branches/end_stage/dbconfig/tasks.md
===================================================================
--- /branches/end_stage/dbconfig/tasks.md	(revision 16082)
+++ /branches/end_stage/dbconfig/tasks.md	(revision 16083)
@@ -1,3 +1,3 @@
-# $Id: tasks.md,v 1.143 2007-12-08 03:17:56 eugene Exp $
+# $Id: tasks.md,v 1.143.2.1 2008-01-15 21:41:05 jhoblitt Exp $
 
 # this table records all exposure ID ever seen from the summit
@@ -95,4 +95,7 @@
     workdir_state STR       64      # key
     reduction   STR         64      # Reduction class
+    dvodb       STR         255
+    tess_id     STR         64
+    end_stage   STR         64      # Key
 END
 
@@ -117,4 +120,7 @@
     workdir     STR         255     # destination for output files
     reduction   STR         64      # Reduction class
+    dvodb       STR         255
+    tess_id     STR         64
+    end_stage   STR         64      # Key
     filter      STR         64
     comment     STR         80
Index: /branches/end_stage/ippTools/share/regtool_pendingexp.sql
===================================================================
--- /branches/end_stage/ippTools/share/regtool_pendingexp.sql	(revision 16082)
+++ /branches/end_stage/ippTools/share/regtool_pendingexp.sql	(revision 16083)
@@ -8,5 +8,8 @@
     workdir,
     workdir_state,
-    reduction
+    reduction,
+    dvodb,
+    tess_id,
+    end_stage
 FROM
     (SELECT
Index: /branches/end_stage/ippTools/src/pxinject.c
===================================================================
--- /branches/end_stage/ippTools/src/pxinject.c	(revision 16082)
+++ /branches/end_stage/ippTools/src/pxinject.c	(revision 16083)
@@ -121,4 +121,22 @@
     if (!status) {
         psError(PS_ERR_UNKNOWN, false, "failed to lookup value for -reduction");
+        return false;
+    }
+
+    psString dvodb = psMetadataLookupStr(&status, config->args, "-dvodb");
+    if (!status) {
+        psError(PS_ERR_UNKNOWN, false, "failed to lookup value for -dvodb");
+        return false;
+    }
+
+    psString tess_id = psMetadataLookupStr(&status, config->args, "-tess_id");
+    if (!status) {
+        psError(PS_ERR_UNKNOWN, false, "failed to lookup value for -tess_id");
+        return false;
+    }
+
+    psString end_stage = psMetadataLookupStr(&status, config->args, "-end_stage");
+    if (!status) {
+        psError(PS_ERR_UNKNOWN, false, "failed to lookup value for -end_stage");
         return false;
     }
@@ -132,5 +150,8 @@
                 workdir,
                 "dirty",
-                reduction
+                reduction,
+                dvodb,
+                tess_id,
+                end_stage
             )
         ) {
Index: /branches/end_stage/ippTools/src/pxinjectConfig.c
===================================================================
--- /branches/end_stage/ippTools/src/pxinjectConfig.c	(revision 16082)
+++ /branches/end_stage/ippTools/src/pxinjectConfig.c	(revision 16083)
@@ -55,4 +55,10 @@
     psMetadataAddStr(newExpArgs, PS_LIST_TAIL, "-reduction",  0,
             "define reduction class", NULL);
+    psMetadataAddStr(newExpArgs, PS_LIST_TAIL, "-dvodb",  0,
+            "define the dvodb for the next processing step", NULL);
+    psMetadataAddStr(newExpArgs, PS_LIST_TAIL, "-tess_id",  0,
+            "define the tess_id for the next processing step", NULL);
+    psMetadataAddStr(newExpArgs, PS_LIST_TAIL, "-end_stage",  0,
+            "define the end goal processing step", NULL);
     psMetadataAddBool(newExpArgs, PS_LIST_TAIL, "-simple",  0,
             "use the simple output format", false);
Index: /branches/end_stage/ippTools/src/pztool.c
===================================================================
--- /branches/end_stage/ippTools/src/pztool.c	(revision 16082)
+++ /branches/end_stage/ippTools/src/pztool.c	(revision 16083)
@@ -615,5 +615,8 @@
                     NULL,               // workdir
                     "dirty",            // workdir state
-                    NULL                // reduction class
+                    NULL,               // reduction class
+                    NULL,               // dvodb
+                    NULL,               // tess_id
+                    NULL                // end_stage
                 )
         ) {
Index: /branches/end_stage/ippTools/src/regtool.c
===================================================================
--- /branches/end_stage/ippTools/src/regtool.c	(revision 16082)
+++ /branches/end_stage/ippTools/src/regtool.c	(revision 16083)
@@ -846,4 +846,5 @@
         return false;
     }
+
     psString exp_name = psMetadataLookupStr(&status, config->args, "-exp_name");
     if (!status) {
@@ -1236,6 +1237,5 @@
     psFree(output);
 
-    if (!rawExpInsert(
-        config->dbh,
+    if (!rawExpInsert(config->dbh,
         (psS64)atoll(exp_id),
         exp_name,
@@ -1248,4 +1248,7 @@
         workdir ? workdir : newExp->workdir,
         reduction ? reduction : newExp->reduction,
+        dvodb ? dvodb : newExp->dvodb,
+        tess_id ? tess_id : newExp->tess_id,
+        end_stage ? end_stage : newExp->end_stage,
         filter,
         comment,
