mirror of
https://github.com/percona/percona-toolkit.git
synced 2025-09-10 03:43:17 +00:00
Add lock_in_share_mode option to NibbleIterator. Silence query_table.pl diag messages.
This commit is contained in:
@@ -5021,6 +5021,7 @@ sub new {
|
||||
: join(', ', map { $q->quote($_) } @cols))
|
||||
. " FROM $tbl->{name}"
|
||||
. ($where ? " WHERE $where" : '')
|
||||
. ($args{lock_in_share_mode} ? " LOCK IN SHARE MODE" : "")
|
||||
. " /*$comments{bite}*/";
|
||||
PTDEBUG && _d('One nibble statement:', $nibble_sql);
|
||||
|
||||
@@ -5030,6 +5031,7 @@ sub new {
|
||||
: join(', ', map { $q->quote($_) } @cols))
|
||||
. " FROM $tbl->{name}"
|
||||
. ($where ? " WHERE $where" : '')
|
||||
. ($args{lock_in_share_mode} ? " LOCK IN SHARE MODE" : "")
|
||||
. " /*explain $comments{bite}*/";
|
||||
PTDEBUG && _d('Explain one nibble statement:', $explain_nibble_sql);
|
||||
|
||||
@@ -5113,6 +5115,7 @@ sub new {
|
||||
. " AND " . $asc->{boundaries}->{'<='} # upper boundary
|
||||
. ($where ? " AND ($where)" : '')
|
||||
. ($args{order_by} ? " ORDER BY $order_by" : "")
|
||||
. ($args{lock_in_share_mode} ? " LOCK IN SHARE MODE" : "")
|
||||
. " /*$comments{nibble}*/";
|
||||
PTDEBUG && _d('Nibble statement:', $nibble_sql);
|
||||
|
||||
@@ -5125,6 +5128,7 @@ sub new {
|
||||
. " AND " . $asc->{boundaries}->{'<='} # upper boundary
|
||||
. ($where ? " AND ($where)" : '')
|
||||
. ($args{order_by} ? " ORDER BY $order_by" : "")
|
||||
. ($args{lock_in_share_mode} ? " LOCK IN SHARE MODE" : "")
|
||||
. " /*explain $comments{nibble}*/";
|
||||
PTDEBUG && _d('Explain nibble statement:', $explain_nibble_sql);
|
||||
|
||||
@@ -8581,6 +8585,7 @@ sub main {
|
||||
dml => $dml,
|
||||
select => $select,
|
||||
callbacks => $callbacks,
|
||||
lock_in_share_mode => 1,
|
||||
OptionParser => $o,
|
||||
Quoter => $q,
|
||||
TableParser => $tp,
|
||||
|
Reference in New Issue
Block a user