/[PAMELA software]/YodaProfiler/src/R2-D2.cpp
ViewVC logotype

Diff of /YodaProfiler/src/R2-D2.cpp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.3 by mocchiut, Mon Nov 13 08:49:49 2006 UTC revision 1.5 by mocchiut, Mon Nov 27 14:25:35 2006 UTC
# Line 377  int main(int numinp, char *inps[]){ Line 377  int main(int numinp, char *inps[]){
377    if ( dtle ){    if ( dtle ){
378      //      //
379      //      //
380      TDatime ti = TDatime(runtime.Data());      TDatime ti = TDatime(tletime.Data());
381      //      //
382      TTimeStamp *time = new TTimeStamp((UInt_t)ti.GetYear(),(UInt_t)ti.GetMonth(),(UInt_t)ti.GetDay(),(UInt_t)ti.GetHour(),(UInt_t)ti.GetMinute(),(UInt_t)ti.GetSecond(),0,true,0);      TTimeStamp *time = new TTimeStamp((UInt_t)ti.GetYear(),(UInt_t)ti.GetMonth(),(UInt_t)ti.GetDay(),(UInt_t)ti.GetHour(),(UInt_t)ti.GetMinute(),(UInt_t)ti.GetSecond(),0,true,0);
383      //      //
# Line 469  int main(int numinp, char *inps[]){ Line 469  int main(int numinp, char *inps[]){
469          exit(-4);          exit(-4);
470        };        };
471        printf("\n Run %u belongs to file %s \n",run,(glroot->PATH+glroot->NAME).Data());        printf("\n Run %u belongs to file %s \n",run,(glroot->PATH+glroot->NAME).Data());
472          filename = glroot->NAME;
473        found = true;        found = true;
474      };      };
475      //      //
# Line 521  int main(int numinp, char *inps[]){ Line 522  int main(int numinp, char *inps[]){
522      } else {      } else {
523        myquery.str("");        myquery.str("");
524        myquery << "select ";        myquery << "select ";
525        myquery << " ID,RUNHEADER_TIME,RUNTRAILER_TIME ";        myquery << " ID,RUNHEADER_TIME,RUNTRAILER_TIME,NEVENTS ";
526        myquery << " from GL_RUN where ID_ROOT_L0=" << ID << ";";            myquery << " from GL_RUN where ID_ROOT_L0=" << ID << ";";    
527        pResult = dbc->Query(myquery.str().c_str());        pResult = dbc->Query(myquery.str().c_str());
528        for( r=0; r < 1000; r++){        for( r=0; r < 1000; r++){
# Line 529  int main(int numinp, char *inps[]){ Line 530  int main(int numinp, char *inps[]){
530          if( Row == NULL ) break;          if( Row == NULL ) break;
531          found = true;          found = true;
532          if ( !r ) printf("\n File %s contains the following runs: \n\n",filename.Data());          if ( !r ) printf("\n File %s contains the following runs: \n\n",filename.Data());
533          TString UTC="UTC";          TString UTC=tzone.Data();
534          printf(" => ID = %i --> the run started at %s UTC ended at %s UTC \n\n",(UInt_t)atoll(Row->GetField(0)),dbtime->ConvertTime(UTC,(UInt_t)atoll(Row->GetField(1))).Data(),dbtime->ConvertTime(UTC,(UInt_t)atoll(Row->GetField(2))).Data());          printf(" => ID = %i --> the run started at %s %s ended at %s %s NEV = %u \n\n",(UInt_t)atoll(Row->GetField(0)),dbtime->ConvertTime(UTC,(UInt_t)atoll(Row->GetField(1))).Data(),tzone.Data(),dbtime->ConvertTime(UTC,(UInt_t)atoll(Row->GetField(2))).Data(),tzone.Data(),(UInt_t)atoll(Row->GetField(3)));
535        };        };
536        delete pResult;          delete pResult;  
537        myquery.str("");        myquery.str("");
# Line 542  int main(int numinp, char *inps[]){ Line 543  int main(int numinp, char *inps[]){
543          Row = pResult->Next();                Row = pResult->Next();      
544          if( Row == NULL ) break;          if( Row == NULL ) break;
545          if ( !r ) printf("\n File %s contains the following DELETED runs: \n\n",filename.Data());          if ( !r ) printf("\n File %s contains the following DELETED runs: \n\n",filename.Data());
546          TString UTC="UTC";          TString UTC=tzone.Data();
547          printf(" => ID = %i --> the run started at %s UTC ended at %s UTC \n\n",(UInt_t)atoll(Row->GetField(0)),dbtime->ConvertTime(UTC,(UInt_t)atoll(Row->GetField(1))).Data(),dbtime->ConvertTime(UTC,(UInt_t)atoll(Row->GetField(2))).Data());          printf(" => ID = %i --> the run started at %s %s ended at %s %s \n\n",(UInt_t)atoll(Row->GetField(0)),dbtime->ConvertTime(UTC,(UInt_t)atoll(Row->GetField(1))).Data(),tzone.Data(),dbtime->ConvertTime(UTC,(UInt_t)atoll(Row->GetField(2))).Data(),tzone.Data());
548        };        };
549        //        //
550        if ( !found ){        if ( !found ){

Legend:
Removed from v.1.3  
changed lines
  Added in v.1.5

  ViewVC Help
Powered by ViewVC 1.1.23