Lines 98-104
my $dbh = C4::Context->dbh;
Link Here
|
98 |
$dbh->{AutoCommit} = 0; |
98 |
$dbh->{AutoCommit} = 0; |
99 |
|
99 |
|
100 |
my $num_bibs_processed = 0; |
100 |
my $num_bibs_processed = 0; |
101 |
my $num_bibs_error = 0; |
101 |
my $num_bibs_updated = 0; |
|
|
102 |
my $num_bibs_error = 0; |
102 |
|
103 |
|
103 |
my $starttime = time(); |
104 |
my $starttime = time(); |
104 |
|
105 |
|
Lines 173-181
sub process_query {
Link Here
|
173 |
else { |
174 |
else { |
174 |
$ret = UpdateTotalIssues( $biblionumber, 0, $totalissues ); |
175 |
$ret = UpdateTotalIssues( $biblionumber, 0, $totalissues ); |
175 |
} |
176 |
} |
176 |
unless ($ret) { |
177 |
if ( $ret == -1 ) { |
177 |
print "Error while processing bib $biblionumber\n" if $verbose; |
178 |
print "Error while processing bib $biblionumber\n" if $verbose; |
178 |
$num_bibs_error++; |
179 |
$num_bibs_error++; |
|
|
180 |
} elsif ( $ret == 1 ) { |
181 |
$num_bibs_updated++; |
179 |
} |
182 |
} |
180 |
} |
183 |
} |
181 |
if ( not $test_only and ( $num_bibs_processed % $commit ) == 0 ) { |
184 |
if ( not $test_only and ( $num_bibs_processed % $commit ) == 0 ) { |
Lines 199-205
Update total issues count script report
Link Here
|
199 |
Run started at: $starttime |
202 |
Run started at: $starttime |
200 |
Run ended at: $endtime |
203 |
Run ended at: $endtime |
201 |
Total run time: $totaltime ms |
204 |
Total run time: $totaltime ms |
202 |
Number of bibs modified: $num_bibs_processed |
205 |
Number of bibs processed: $num_bibs_processed |
|
|
206 |
Number of bibs modified: $num_bibs_updated |
203 |
Number of bibs with error: $num_bibs_error |
207 |
Number of bibs with error: $num_bibs_error |
204 |
_SUMMARY_ |
208 |
_SUMMARY_ |
205 |
$summary .= "\n**** Ran in test mode only ****\n" if $test_only; |
209 |
$summary .= "\n**** Ran in test mode only ****\n" if $test_only; |
206 |
- |
|
|