Index: branches/cleanup/ippTools/src/dettool.c
===================================================================
--- branches/cleanup/ippTools/src/dettool.c	(revision 18153)
+++ branches/cleanup/ippTools/src/dettool.c	(revision 18357)
@@ -87,4 +87,6 @@
 static bool detrunsummaryMode(pxConfig *config);
 static bool revertdetrunsummaryMode(pxConfig *config);
+static bool updatedetrunsummaryMode(pxConfig *config);
+// run
 static bool updatedetrunMode(pxConfig *config);
 static bool rerunMode(pxConfig *config);
@@ -179,4 +181,5 @@
         MODECASE(DETTOOL_MODE_DETRUNSUMMARY,    detrunsummaryMode);
         MODECASE(DETTOOL_MODE_REVERTDETRUNSUMMARY, revertdetrunsummaryMode);
+        MODECASE(DETTOOL_MODE_UPDATEDETRUNSUMMARY, updatedetrunsummaryMode);
         MODECASE(DETTOOL_MODE_UPDATEDETRUN,     updatedetrunMode);
         MODECASE(DETTOOL_MODE_RERUN,            rerunMode);
@@ -456,10 +459,4 @@
     }
 
-    if (!convertIdToStr(detRuns)) {
-        psError(PS_ERR_UNKNOWN, false, "failed to convert id fields into a strings");
-        psFree(detRuns);
-        return false;
-    }
-
     // negative simple so the default is true
     if (!ippdbPrintMetadatas(stdout, detRuns, "detRun", !simple)) {
@@ -719,11 +716,4 @@
     }
 
-    // convert det_id to a string externaly
-    if (!convertIdToStr(detRuns)) {
-        psError(PS_ERR_UNKNOWN, false, "failed to convert det_id to a string");
-        psFree(detRuns);
-        return false;
-    }
-
     // negative simple so the default is true
     if (!ippdbPrintMetadatas(stdout, detRuns, "detRun", !simple)) {
@@ -1012,11 +1002,4 @@
     }
 
-    // convert det_id to a string externaly
-    if (!convertIdToStr(detRuns)) {
-        psError(PS_ERR_UNKNOWN, false, "failed to convert id fields into a strings");
-        psFree(detRuns);
-        return false;
-    }
-
     // negative simple so the default is true
     if (!ippdbPrintMetadatas(stdout, newDetRuns, "detRun", !simple)) {
@@ -1111,11 +1094,4 @@
         psFree(runs);
         return true;
-    }
-
-    // convert det_id to a string externaly
-    if (!convertIdToStr(runs)) {
-        psError(PS_ERR_UNKNOWN, false, "failed to convert id fields into a strings");
-        psFree(runs);
-        return false;
     }
 
@@ -1180,11 +1156,4 @@
         psFree(output);
         return true;
-    }
-
-    // convert det_id to a string externaly
-    if (!convertIdToStr(output)) {
-        psError(PS_ERR_UNKNOWN, false, "failed to convert id fields into a strings");
-        psFree(output);
-        return false;
     }
 
@@ -3851,4 +3820,34 @@
 
 
+static bool updatedetrunsummaryMode(pxConfig *config)
+{
+    PS_ASSERT_PTR_NON_NULL(config, false);
+
+    // required
+    PXOPT_LOOKUP_STR(det_id, config->args, "-det_id", true, false);
+
+    PXOPT_LOOKUP_BOOL(accept, config->args, "-accept", false);
+    PXOPT_LOOKUP_BOOL(reject, config->args, "-reject", false);
+
+    if (accept && reject) {
+        psError(PS_ERR_UNKNOWN, true, "-accept and -reject are exclusive");
+        return false;
+    }
+
+    if (!(accept || reject)) {
+        psError(PS_ERR_UNKNOWN, true, "either -accept or -reject is required");
+        return false;
+    }
+
+    char *query = "UPDATE detRunSummary SET accept = %d WHERE det_id = %"PRId64; 
+    if (!p_psDBRunQuery(config->dbh, query, accept, (psS64)atoll(det_id))) {
+        psError(PS_ERR_UNKNOWN, false, "database error");
+        return false;
+    }
+
+    return true;
+}
+
+
 static bool updatedetrunMode(pxConfig *config)
 {
@@ -4252,10 +4251,4 @@
     }
 
-    if (!convertIdToStr(detRuns)) {
-        psError(PS_ERR_UNKNOWN, false, "failed to convert id fields into a strings");
-        psFree(detRuns);
-        return false;
-    }
-
     // negative simple so the default is true
     if (!ippdbPrintMetadatas(stdout, detRuns, "detRun", !simple)) {
