Changeset 7467 for trunk/MagicSoft/Mars/datacenter/macros
- Timestamp:
- 01/31/06 14:53:08 (19 years ago)
- Location:
- trunk/MagicSoft/Mars/datacenter/macros
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/datacenter/macros/getdolist.C
r7464 r7467 130 130 rc.GetValue(table+".TimerTable", ""), 131 131 rc.GetValue(table+".Primary", "")); 132 query+=Form(" WHERE ISNULL(%s) AND ISNULL(fFailed ) AND ISNULL(fStartTime) AND ISNULL(fFailedTime) ", column.Data());132 query+=Form(" WHERE ISNULL(%s) AND ISNULL(fFailedCode) AND ISNULL(fFailedComment) AND ISNULL(fStartTime) AND ISNULL(fFailedTime) ", column.Data()); 133 133 134 134 TIter Next(&l); -
trunk/MagicSoft/Mars/datacenter/macros/setstatus.C
r7464 r7467 33 33 // 34 34 // Usage: 35 // .x setstatus.C+("primary","table","column","statustime","failed ","starttime","failedtime",kTRUE)35 // .x setstatus.C+("primary","table","column","statustime","failedcode","failedcomment","starttime","failedtime",kTRUE) 36 36 // The first argument is the primary (date/run/sequence/dataset), the second 37 37 // and third argument give the table and column of the step. The fourth 38 38 // column is giving the statustime, to which the column has to be set. The 39 39 // fifth argument is giving the error code (in case of failure), the sixth 40 // the starttime and the seventh the stoptime (only in case of failure). 40 // an error comment, the seventh the starttime and the eigth the stoptime 41 // (only in case of failure). 41 42 // The last argument is indicating if the columns of all influenced steps 42 43 // shall be reset to NULL. The default is kTRUE, which means, that the … … 122 123 TString influences = rc.GetValue(table+"."+column+".Influences", ""); 123 124 124 TString query(Form("UPDATE %s SET %s=%s, fFailed=%s, f StartTime=%s, fFailedTime=%s ",125 TString query(Form("UPDATE %s SET %s=%s, fFailed=%s, fFailedTime=%s ", 125 126 table.Data(), column.Data(), statustime.Data(), failed.Data(), 126 starttime.Data(), failedtime.Data())); 127 failedtime.Data())); 128 if (starttime.CompareTo("noreset")) 129 query += Form(", fStartTime=%s", starttime.Data()); 127 130 128 131 while (!influences.IsNull() && resetall) … … 160 163 } 161 164 162 int setstatus(TString primary, TString table, TString column, TString statustime, TString failed , TString starttime, TString failedtime, Bool_t resetall=kTRUE)165 int setstatus(TString primary, TString table, TString column, TString statustime, TString failedcode, TString failedcomment, TString starttime, TString failedtime, Bool_t resetall=kTRUE) 163 166 { 164 167 TEnv env("sql.rc"); … … 179 182 180 183 //if reset is needed and/or can be done, set new values 181 return !CheckReset(rc, table, column, statustime) ? 0 : SetInfluences(serv, rc, primary, table, column, statustime, failed , starttime, failedtime, resetall);184 return !CheckReset(rc, table, column, statustime) ? 0 : SetInfluences(serv, rc, primary, table, column, statustime, failedcode, failedcomment, starttime, failedtime, resetall); 182 185 183 186 }
Note:
See TracChangeset
for help on using the changeset viewer.