Good day all I have a script that is using Array::Compare and for some reason when I print the output of the compare I am getting a slew of numbers instead of the actaul lines that are different in the two files.
Below is a copy of my code and the output file if anyone can help with this one please do I am lost.
#!/usr/bin/perl -w
use Array::Compare;
use strict;
my $file1 = "/var/tmp/db.bind1";
my $file2 = "/var/tmp/db.bind2";
my $out = "/var/tmp/compare_out";
open(FILE1, "$file1") || die "Can't open $file1 to read\nReason: $!\n
+";
my @file1 = <FILE1>;
close(FILE1);
open(FILE2, "$file2") || die "Can't open $file2 to read\nReason: $!\n
+";
my @file2 = <FILE2>;
close(FILE2);
open(OUT, ">$out") || die "Cant create $out\nReason: $!\n";
my $comp = Array::Compare->new(DefFull => 1);
#$comp->compare(\@file1, \@file2);
print OUT $comp->full_compare(\@file1,\@file2);
close(OUT);
exit;
Here is the output file:
# more compare_out
3945739458394593946039461394623946339464394653946639467394683946939470
+394713947239473394743947539476394773947839479394803948139482394833948
+439485394863948739488394893949039491394923949339494394953949639497394
+983949939500395013950239503395043950539506395073950839509395103951139
+512395133951439515395163951739518395193952039521395223952339524395253
+952639527395283952939530395313953239533395343953539536395373953839539
+395403954139542395433954439545395463954739548395493955039551395523955
+339554395553955639557395583955939560395613956239563395643956539566395
+673956839569395703957139572395733957439575395763957739578395793958039
+581395823958339584395853958639587395883958939590395913959239593395943
+959539596395973959839599396003960139602396033960439605396063960739608
+396093961039611396123961339614396153961639617396183961939620396213962
+239623396243962539626396273962839629396303963139632396333963439635396
+363963739638396393964039641396423964339644396453964639647396483964939
+650396513965239653396543965539656396573965839659396603966139662396633
+966439665396663966739668396693967039671396723967339674396753967639677
+396783967939680396813968239683396843968539686396873968839689396903969
+139692396933969439695396963969739698396993970039701397023970339704397
+053970639707397083970939710397113971239713397143971539716397173971839
+719397203972139722397233972439725397263972739728397293973039731397323
+973339734397353973639737397383973939740397413974239743397443974539746
+397473974839749397503975139752397533975439755397563975739758397593976
+039761397623976339764397653976639767397683976939770397713977239773397
+74