From b9675c56b6606eba5e0c7c28fb9acd6e461cf3d7 Mon Sep 17 00:00:00 2001 From: Marco Tusa Date: Fri, 22 Sep 2023 17:32:27 +0200 Subject: [PATCH] small bug in regex --- bin/pt-show-grants | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/pt-show-grants b/bin/pt-show-grants index 96574ce7..8ffd2b13 100644 --- a/bin/pt-show-grants +++ b/bin/pt-show-grants @@ -2067,7 +2067,7 @@ sub main { $create =~ s{ BY }{ AS }; if ( $create =~ m/caching_sha2_password/ ) { print "-- Converting $user_host caching_sha2_password to binary for correct export/import\n"; - $create =~ s/\sAS\s.*'\s|$/ AS $pw_bin /g; + $create =~ s/\sAS\s.*'\s/ AS $pw_bin /g; } $alter =~ s{CREATE USER}{ALTER USER}; # Alter user should not be pass in the latest MySQL version