LotusNotes::LoadExport is a Perl module designed to read text files generated from a LotusNotes 'Structured Text' export. Normally the 'Word wrap within documents' entry (as part of the export) is set to 999 characters (as many 9's as you can enter in the field). The 'Separator between documents' is assumed to be linefeed (the export default).
Load records from a Lotus Notes database export.
Expects an array reference of fields to extract.
Returns an array reference of hashes where each hash represents a record
SYNOPSIS
#! perl -w
use strict;
use LotusNotes::LoadExport;
use Data::Dumper;
$Data::Dumper::Indent = 1;
my @labels = (qw{ VersionLic AppName Version UserID WorkstationID });
# Here application_license.txt is a LotusNotes export (see DESCRIPTION below)
my $ln = LotusNotes::LoadExport->new(filename => 'application_license.txt', fieldnames => \@labels);
# Get ALL the data (you may not want to do this - see next below)
my $data = $ln->load();
print Dumper($data), "\n";
exit;
# Iterator based data access
while (my $data = $ln->get_next())
{
# Do something with each record
print Dumper($data), "\n";
}
Example output:
$VAR1 = [
{
'AppName' => 'ABC Flowcharter',
'Version' => '7.0',
'WorkstationID' => 'PC-1234',
'UserID' => 'tom.smith',
'VersionLic' => '7.0'
},
{
'AppName' => 'MS-Access',
'Version' => '2007',
'WorkstationID' => 'PC-3043',
'UserID' => 'sally.jones'
}
];
Product's homepage
Requirements:
· Perl