From: Chris Hilton Date: Mon, 5 Mar 2007 20:02:34 +0000 (+0000) Subject: Skip constraint and index comparison shortcuts when ignoring the relevant names X-Git-Tag: v0.11008~380 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=03739eb3d4372c1dd36d350143bce670c7654894;p=dbsrgits%2FSQL-Translator.git Skip constraint and index comparison shortcuts when ignoring the relevant names --- diff --git a/lib/SQL/Translator/Diff.pm b/lib/SQL/Translator/Diff.pm index 8ac37c9..8d893f7 100644 --- a/lib/SQL/Translator/Diff.pm +++ b/lib/SQL/Translator/Diff.pm @@ -231,7 +231,7 @@ END } INDEX2: for my $i_src ( $src_table->get_indices ) { - next if $checked_indices{$i_src}; + next if !$ignore_index_names && $checked_indices{$i_src}; for my $i_tar ( $tar_table->get_indices ) { next INDEX2 if $i_src->equals($i_tar, $case_insensitive, $ignore_index_names); } @@ -258,7 +258,7 @@ END for my $c_src ( $src_table->get_constraints ) { next if $source_db =~ /Oracle/ && $c_src->type eq UNIQUE && $c_src->name =~ /^SYS_/i; # Ignore Oracle SYS_ constraints hack - next if $checked_constraints{$c_src}; + next if !$ignore_constraint_names && $checked_constraints{$c_src}; for my $c_tar ( $tar_table->get_constraints ) { next CONSTRAINT2 if $c_src->equals($c_tar, $case_insensitive, $ignore_constraint_names); }