Ignore:
Timestamp:
2010-07-22T18:55:18+12:00 (14 years ago)
Author:
ak19
Message:
  1. Dr Bainbridge fixed the database perl modules to all have the method read_info_keys (which reads the keys from the database into a map), so that dbutil.pm can have the same as a generic method. 2. buildConfigxml.pm only writes out the defaultIndex if it is set (to prevent an Uninitialised Variable warning message from Perl).
File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone2/perllib/dbutil/sqlite.pm

    r22076 r22485  
    141141  }
    142142
     143}
     144
     145
     146sub read_infodb_keys
     147{
     148  my $infodb_file_path = shift(@_);
     149  my $infodb_map = shift(@_);
     150
     151
     152  my $keys_str = read_infodb_cmd($infodb_file_path,"SELECT key FROM data;");
     153
     154  my @keys = split(/\n/,$keys_str);
     155
     156  foreach my $key (@keys)
     157  {
     158      $infodb_map->{$key} = 1;
     159  }
    143160}
    144161
Note: See TracChangeset for help on using the changeset viewer.