summaryrefslogtreecommitdiff
path: root/check_postgres.pl
diff options
context:
space:
mode:
authorGreg2009-06-02 00:55:31 +0000
committerGreg2009-06-02 00:55:31 +0000
commit909a7e50f33efd83545574a2be07e086d6eef6fb (patch)
tree0d86c22dcadbb8a05d18e835a0d80cbc7b79e1ca /check_postgres.pl
parent6f0332c0e106c65ca7c12d263385a4ff18fcfdb9 (diff)
Show everything in same_schema one-per-line, simply easier to human parse.
Diffstat (limited to 'check_postgres.pl')
-rwxr-xr-xcheck_postgres.pl60
1 files changed, 30 insertions, 30 deletions
diff --git a/check_postgres.pl b/check_postgres.pl
index a1ca1f241..a3c60b3e1 100755
--- a/check_postgres.pl
+++ b/check_postgres.pl
@@ -5023,14 +5023,14 @@ sub check_same_schema {
if (exists $fail{schemas}) {
if (exists $fail{schemas}{notexist}) {
if (exists $fail{schemas}{notexist}{1}) {
- $db->{perf} .= ' Schemas in 1 but not 2: ';
- $db->{perf} .= join ', ' => @{$fail{schemas}{notexist}{1}};
- $db->{perf} .= ' ';
+ for my $name (@{$fail{schemas}{notexist}{1}}) {
+ $db->{perf} .= " Schema in 1 but not 2: $name ";
+ }
}
if (exists $fail{schemas}{notexist}{2}) {
- $db->{perf} .= ' Schemas in 2 but not 1: ';
- $db->{perf} .= join ', ' => @{$fail{schemas}{notexist}{2}};
- $db->{perf} .= ' ';
+ for my $name (@{$fail{schemas}{notexist}{2}}) {
+ $db->{perf} .= " Schema in 2 but not 1: $name ";
+ }
}
}
if (exists $fail{schemas}{diffowners}) {
@@ -5051,14 +5051,14 @@ sub check_same_schema {
if (exists $fail{tables}) {
if (exists $fail{tables}{notexist}) {
if (exists $fail{tables}{notexist}{1}) {
- $db->{perf} .= ' Tables in 1 but not 2: ';
- $db->{perf} .= join ', ' => @{$fail{tables}{notexist}{1}};
- $db->{perf} .= ' ';
+ for my $name (@{$fail{tables}{notexist}{1}}) {
+ $db->{perf} .= " Table in 1 but not 2: $name ";
+ }
}
if (exists $fail{tables}{notexist}{2}) {
- $db->{perf} .= ' Tables in 2 but not 1: ';
- $db->{perf} .= join ', ' => @{$fail{tables}{notexist}{2}};
- $db->{perf} .= ' ';
+ for my $name (@{$fail{tables}{notexist}{2}}) {
+ $db->{perf} .= " Table in 2 but not 1: $name ";
+ }
}
}
if (exists $fail{tables}{diffowners}) {
@@ -5079,14 +5079,14 @@ sub check_same_schema {
if (exists $fail{sequences}) {
if (exists $fail{sequences}{notexist}) {
if (exists $fail{sequences}{notexist}{1}) {
- $db->{perf} .= ' Sequences in 1 but not 2: ';
- $db->{perf} .= join ', ' => @{$fail{sequences}{notexist}{1}};
- $db->{perf} .= ' ';
+ for my $name (@{$fail{sequences}{notexist}{1}}) {
+ $db->{perf} .= " Sequence in 1 but not 2: $name ";
+ }
}
if (exists $fail{sequences}{notexist}{2}) {
- $db->{perf} .= ' Sequences in 2 but not 1: ';
- $db->{perf} .= join ', ' => @{$fail{sequences}{notexist}{2}};
- $db->{perf} .= ' ';
+ for my $name (@{$fail{sequences}{notexist}{2}}) {
+ $db->{perf} .= " Sequence in 2 but not 1: $name ";
+ }
}
}
if (exists $fail{sequences}{diffowners}) {
@@ -5107,14 +5107,14 @@ sub check_same_schema {
if (exists $fail{views}) {
if (exists $fail{views}{notexist}) {
if (exists $fail{views}{notexist}{1}) {
- $db->{perf} .= ' Views in 1 but not 2: ';
- $db->{perf} .= join ', ' => @{$fail{views}{notexist}{1}};
- $db->{perf} .= ' ';
+ for my $name (@{$fail{views}{notexist}{1}}) {
+ $db->{perf} .= " View in 1 but not 2: $name ";
+ }
}
if (exists $fail{views}{notexist}{2}) {
- $db->{perf} .= ' Views in 2 but not 1: ';
- $db->{perf} .= join ', ' => @{$fail{views}{notexist}{2}};
- $db->{perf} .= ' ';
+ for my $name (@{$fail{views}{notexist}{2}}) {
+ $db->{perf} .= " View in 2 but not 1: $name ";
+ }
}
}
if (exists $fail{views}{diffowners}) {
@@ -5135,14 +5135,14 @@ sub check_same_schema {
if (exists $fail{triggers}) {
if (exists $fail{triggers}{notexist}) {
if (exists $fail{triggers}{notexist}{1}) {
- $db->{perf} .= ' Triggers in 1 but not 2: ';
- $db->{perf} .= join ', ' => @{$fail{triggers}{notexist}{1}};
- $db->{perf} .= ' ';
+ for my $name (@{$fail{triggers}{notexist}{1}}) {
+ $db->{perf} .= " Trigger in 1 but not 2: $name ";
+ }
}
if (exists $fail{triggers}{notexist}{2}) {
- $db->{perf} .= ' Triggers in 2 but not 1: ';
- $db->{perf} .= join ', ' => @{$fail{triggers}{notexist}{2}};
- $db->{perf} .= ' ';
+ for my $name (@{$fail{triggers}{notexist}{2}}) {
+ $db->{perf} .= " Trigger in 2 but not 1: $name ";
+ }
}
}
if (exists $fail{triggers}{difffunc}) {