[BACK]Return to MemoDB2ClassicNote.pl CVS log [TXT][DIR] Up to [local] / palm / MemoDB2ClassicNote

Diff for /palm/MemoDB2ClassicNote/MemoDB2ClassicNote.pl between version 1.3 and 1.4

version 1.3, 2010/03/09 21:29:46 version 1.4, 2010/03/10 18:50:31
Line 14 
Line 14 
 #      COMPANY:  Red River Communications  #      COMPANY:  Red River Communications
 #      VERSION:  1.0  #      VERSION:  1.0
 #      CREATED:  03/09/10 11:22:52  #      CREATED:  03/09/10 11:22:52
 #     REVISION:  $AFresh1: MemoDB2ClassicNote.pl,v 1.2 2010/03/09 20:55:05 andrew Exp $  #     REVISION:  $AFresh1: MemoDB2ClassicNote.pl,v 1.3 2010/03/09 21:29:46 andrew Exp $
 #===============================================================================  #===============================================================================
   
 use strict;  use strict;
Line 40 
Line 40 
     @categories = ('undefined');      @categories = ('undefined');
 }  }
   
   my $count = 0;
 my $cat_sth = $dbh->prepare(  my $cat_sth = $dbh->prepare(
     'INSERT INTO categories ("cat_id", "category") VALUES (?,?)');      'INSERT INTO categories ("cat_id", "category") VALUES (?,?)');
 foreach my $id ( 0 .. @categories ) {  foreach my $id ( 0 .. @categories ) {
     my $name = $categories[$id]->{name};      my $name = $categories[$id]->{name};
     next if !$name;      next if !$name;
   
     print "Category: $id $name\n";      $count++;
       print "Category [$count]: $id $name\n";
     $cat_sth->execute( $id, $name ) or die $cat_sth->errstr;      $cat_sth->execute( $id, $name ) or die $cat_sth->errstr;
 }  }
   
   $count = 0;
 my $rec_sth  my $rec_sth
     = $dbh->prepare( 'INSERT INTO'      = $dbh->prepare( 'INSERT INTO'
         . ' memos ("cat_id", "head", "memo", "privat")'          . ' memos ("cat_id", "head", "memo", "privat")'
Line 67 
Line 70 
         $private = 1;          $private = 1;
     }      }
   
     print "Record: $head\n";      $count++;
       print "Record [$count]: $head\n";
   
     $rec_sth->execute( $record->{category}, $head, $data, $private )      $rec_sth->execute( $record->{category}, $head, $data, $private )
         or die $cat_sth->errstr;          or die $cat_sth->errstr;

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

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