Lines 205-214
MARC21 only. Prefer records which come from ABC based on the 003 field.
Link Here
|
205 |
=cut |
205 |
=cut |
206 |
|
206 |
|
207 |
when (/^source=(.*)$/) { |
207 |
when (/^source=(.*)$/) { |
|
|
208 |
my $goal = $1; |
208 |
push @selectors, sub { |
209 |
push @selectors, sub { |
209 |
return ( |
210 |
return ( |
210 |
defined $_[0]->{'record'}->field('003') |
211 |
defined $_[0]->{'record'}->field('003') |
211 |
&& $_[0]->{'record'}->field('003')->data() eq $1 |
212 |
&& $_[0]->{'record'}->field('003')->data() eq $goal |
212 |
? 1 |
213 |
? 1 |
213 |
: 0 |
214 |
: 0 |
214 |
); |
215 |
); |
Lines 265-277
if ( $match =~ m#/# ) {
Link Here
|
265 |
$matcher->threshold( 1000 * scalar(@matchers) - 1 ); |
266 |
$matcher->threshold( 1000 * scalar(@matchers) - 1 ); |
266 |
$matcher->code('TEMP'); |
267 |
$matcher->code('TEMP'); |
267 |
$matcher->description('Temporary matcher for deduplication run'); |
268 |
$matcher->description('Temporary matcher for deduplication run'); |
268 |
while ( $matchers[ $cnt++ ] =~ m#^([^/]+)/([0-9]{3})(.*)$# ) { |
269 |
while ( $matchers[ $cnt ] && $matchers[ $cnt++ ] =~ m#^([^/]+)/([0-9]{3})(.*)$# ) { |
269 |
$matcher->add_simple_matchpoint( $1, 1000, $2, $3, 0, 0, '' ); |
270 |
$matcher->add_simple_matchpoint( $1, 1000, $2, $3, 0, 0, '' ); |
270 |
} |
271 |
} |
|
|
272 |
$check ||= ''; |
271 |
my @checks = split( ',', $check ); |
273 |
my @checks = split( ',', $check ); |
272 |
$cnt = 0; |
274 |
$cnt = 0; |
273 |
while ( $checks[ $cnt++ ] =~ m#^([0-9]{3})(.*)$# ) { |
275 |
while ( $checks[ $cnt ] && $checks[ $cnt++ ] =~ m#^([0-9]{3})(.*)$# ) { |
274 |
$matcher->add_simple_required_check( $1, $2, 0, 0, $1, $2, 0, 0, '' ); |
276 |
$matcher->add_simple_required_check( $1, $2, 0, 0, '', $1, $2, 0, 0, '' ); |
275 |
} |
277 |
} |
276 |
} |
278 |
} |
277 |
else { |
279 |
else { |
278 |
- |
|
|