[LON-CAPA-cvs] cvs: loncom /interface lonmysql.pm

matthew lon-capa-cvs@mail.lon-capa.org
Mon, 12 Aug 2002 14:50:18 -0000


matthew		Mon Aug 12 10:50:18 2002 EDT

  Modified files:              
    /loncom/interface	lonmysql.pm 
  Log:
  No need to escape and unescape values.  This was preventing dates from 
  being stored properly.
  
  
Index: loncom/interface/lonmysql.pm
diff -u loncom/interface/lonmysql.pm:1.5 loncom/interface/lonmysql.pm:1.6
--- loncom/interface/lonmysql.pm:1.5	Fri Aug  9 13:08:19 2002
+++ loncom/interface/lonmysql.pm	Mon Aug 12 10:50:18 2002
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # MySQL utility functions
 #
-# $Id: lonmysql.pm,v 1.5 2002/08/09 17:08:19 matthew Exp $
+# $Id: lonmysql.pm,v 1.6 2002/08/12 14:50:18 matthew Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -656,11 +656,6 @@
     }
     $debugstring = "Got rows matching $condition";
     my @Results = @{$sth->fetchall_arrayref};
-    foreach my $row (@Results) {
-        for(my $i=0;$i<@$row;$i++) {
-            $row->[$i]=&Apache::lonnet::unescape($row->[$i]);
-        }
-    }
     return @Results;
 }
 
@@ -710,7 +705,7 @@
         @Parameters = @$rowdata;
     } elsif (ref($rowdata) eq 'HASH') {
         foreach (@{$Tables{$tablename}->{'Col_order'}}) {
-            push(@Parameters,&Apache::lonnet::escape($rowdata->{$_}));
+            push(@Parameters,$rowdata->{$_});
         }
     } 
     $sth->execute(@Parameters);