Diff for /loncom/interface/statistics/lonproblemstatistics.pm between versions 1.17 and 1.18

version 1.17, 2002/08/09 19:49:30 version 1.18, 2002/08/12 18:21:42
Line 48  sub BuildProblemStatisticsPage { Line 48  sub BuildProblemStatisticsPage {
     my ($cacheDB, $students, $courseID, $c, $r)=@_;      my ($cacheDB, $students, $courseID, $c, $r)=@_;
     my %cache;      my %cache;
   
     unless(tie(%cache,'GDBM_File',$cacheDB,&GDBM_READER,0640)) {      unless(tie(%cache,'GDBM_File',$cacheDB,&GDBM_READER(),0640)) {
         return '<html><body>Unable to tie database.</body></html>';          return '<html><body>Unable to tie database.</body></html>';
     }      }
   
Line 80  sub BuildProblemStatisticsPage { Line 80  sub BuildProblemStatisticsPage {
         my $courseData =           my $courseData = 
             &Apache::loncoursedata::DownloadCourseInformation($_, $courseID);              &Apache::loncoursedata::DownloadCourseInformation($_, $courseID);
         last if ($c->aborted());          last if ($c->aborted());
         if(tie(%cache,'GDBM_File',$cacheDB,&GDBM_WRCREAT,0640)) {          if(tie(%cache,'GDBM_File',$cacheDB,&GDBM_WRCREAT(),0640)) {
             &Apache::loncoursedata::ProcessStudentData(\%cache,               &Apache::loncoursedata::ProcessStudentData(\%cache, 
                                                        $courseData, $_);                                                         $courseData, $_);
             untie(%cache);              untie(%cache);
Line 90  sub BuildProblemStatisticsPage { Line 90  sub BuildProblemStatisticsPage {
     &Close_PrgWin($r);      &Close_PrgWin($r);
     if($c->aborted()) { return; }      if($c->aborted()) { return; }
   
     unless(tie(%cache,'GDBM_File',$cacheDB,&GDBM_READER,0640)) {      unless(tie(%cache,'GDBM_File',$cacheDB,&GDBM_READER(),0640)) {
         return '<html><body>Unable to tie database.</body></html>';          return '<html><body>Unable to tie database.</body></html>';
     }      }
   
Line 125  sub BuildProblemStatisticsPage { Line 125  sub BuildProblemStatisticsPage {
   
     foreach (keys %$TempCache) {      foreach (keys %$TempCache) {
         last if ($c->aborted());          last if ($c->aborted());
         if(tie(%cache,'GDBM_File',$cacheDB,&GDBM_WRCREAT,0640)) {          if(tie(%cache,'GDBM_File',$cacheDB,&GDBM_WRCREAT(),0640)) {
     $cache{$_}=$TempCache->{$_};      $cache{$_}=$TempCache->{$_};
   
             untie(%cache);              untie(%cache);
Line 874  sub BuildGraphicChart { Line 874  sub BuildGraphicChart {
     my $count = 0;      my $count = 0;
     my $Max = 0;      my $Max = 0;
   
     unless(tie(%cache,'GDBM_File',$cacheDB,&GDBM_READER,0640)) {      unless(tie(%cache,'GDBM_File',$cacheDB,&GDBM_READER(),0640)) {
         return '<html><body>Unable to tie database.</body></html>';          return '<html><body>Unable to tie database.</body></html>';
     }      }
         

Removed from v.1.17  
changed lines
  Added in v.1.18


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>