MARC-Errorchecks
view release on metacpan or search on metacpan
lib/MARC/BBMARC.pm view on Meta::CPAN
241242243244245246247248249250251252253254255256257258259260261=head2 updated_record_array()
Note: Creates an array of control numbers (001) from input file.
Use with merge marc script. Call to initialize updated record array variable prior to entering loop.
Prompts for updated record file.
Prints running count of records based on counting_print function. Works only with USMARC input files.
=cut
sub
updated_record_array {
my
@updatedrecarray
;
####################################
# To do: test abstracted input file call ##
####################################
my
$inputfile
=
shift
;
unless
(
$inputfile
) {
(
"What is the updated record file?:"
);
$inputfile
= <>;
lib/MARC/BBMARC.pm view on Meta::CPAN
637638639640641642643644645646647648649650651652653654655656657This may be very memory intensive as it stores raw MARC
for
each
record in the updated (first) file,
with
its associated control number.
40000+ records (43815K on disk) take approximately 102,192K+ to
read
in and then dereference.
YOU HAVE BEEN WARNED!!!
=head2 TO DO (on updated_record_hash)
Reduce memory usage, probably by learning how to tie hash to file instead of storing everything in memory.
=cut
sub
updated_record_hash {
my
%updatedrechash
;
#retrieve file name if one was passed
my
$inputfile
=
shift
;
#otherwise get file name
unless
(
$inputfile
) {
(
"What is the updated record file?:"
);
$inputfile
= <>;
( run in 0.612 second using v1.01-cache-2.11-cpan-49f99fa48dc )