mirror of
https://github.com/percona/percona-toolkit.git
synced 2025-09-11 05:29:30 +00:00
PT-1518 pt-table-checksum gives error CRC32 (#415)
This commit is contained in:
@@ -6190,7 +6190,10 @@ sub _get_crc_type {
|
|||||||
$type = $sth->{mysql_type_name}->[0];
|
$type = $sth->{mysql_type_name}->[0];
|
||||||
$length = $sth->{mysql_length}->[0];
|
$length = $sth->{mysql_length}->[0];
|
||||||
PTDEBUG && _d($sql, $type, $length);
|
PTDEBUG && _d($sql, $type, $length);
|
||||||
if ( $type eq 'bigint' && $length < 20 ) {
|
if ( $type eq 'integer' && $length < 11 ) {
|
||||||
|
$type = 'int';
|
||||||
|
}
|
||||||
|
elsif ( $type eq 'bigint' && $length < 20 ) {
|
||||||
$type = 'int';
|
$type = 'int';
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@@ -4747,7 +4747,10 @@ sub get_crc_type {
|
|||||||
$type = $sth->{mysql_type_name}->[0];
|
$type = $sth->{mysql_type_name}->[0];
|
||||||
$length = $sth->{mysql_length}->[0];
|
$length = $sth->{mysql_length}->[0];
|
||||||
PTDEBUG && _d($sql, $type, $length);
|
PTDEBUG && _d($sql, $type, $length);
|
||||||
if ( $type eq 'bigint' && $length < 20 ) {
|
if ( $type eq 'integer' && $length < 11 ) {
|
||||||
|
$type = 'int';
|
||||||
|
}
|
||||||
|
elsif ( $type eq 'bigint' && $length < 20 ) {
|
||||||
$type = 'int';
|
$type = 'int';
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@@ -338,7 +338,10 @@ sub _get_crc_type {
|
|||||||
$type = $sth->{mysql_type_name}->[0];
|
$type = $sth->{mysql_type_name}->[0];
|
||||||
$length = $sth->{mysql_length}->[0];
|
$length = $sth->{mysql_length}->[0];
|
||||||
PTDEBUG && _d($sql, $type, $length);
|
PTDEBUG && _d($sql, $type, $length);
|
||||||
if ( $type eq 'bigint' && $length < 20 ) {
|
if ( $type eq 'integer' && $length < 11 ) {
|
||||||
|
$type = 'int';
|
||||||
|
}
|
||||||
|
elsif ( $type eq 'bigint' && $length < 20 ) {
|
||||||
$type = 'int';
|
$type = 'int';
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@@ -88,7 +88,10 @@ sub get_crc_type {
|
|||||||
$type = $sth->{mysql_type_name}->[0];
|
$type = $sth->{mysql_type_name}->[0];
|
||||||
$length = $sth->{mysql_length}->[0];
|
$length = $sth->{mysql_length}->[0];
|
||||||
PTDEBUG && _d($sql, $type, $length);
|
PTDEBUG && _d($sql, $type, $length);
|
||||||
if ( $type eq 'bigint' && $length < 20 ) {
|
if ( $type eq 'integer' && $length < 11 ) {
|
||||||
|
$type = 'int';
|
||||||
|
}
|
||||||
|
elsif ( $type eq 'bigint' && $length < 20 ) {
|
||||||
$type = 'int';
|
$type = 'int';
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
Reference in New Issue
Block a user