diff options
author | Robert Bindar <robert@mariadb.org> | 2021-02-02 14:57:16 +0200 |
---|---|---|
committer | Robert Bindar <robert@mariadb.org> | 2021-03-08 12:07:06 +0200 |
commit | 363ba107842127c8b23869b314a285e914f4a74f (patch) | |
tree | 47cf2e27cf19187408644f0d4da73a7ed33b9fb3 /scripts/mysql_system_tables_fix.sql | |
parent | a26e7a37266d8296094dabca52f0f6646fd73926 (diff) | |
download | mariadb-git-363ba107842127c8b23869b314a285e914f4a74f.tar.gz |
MDEV-24363 mysql.user password_expired column is incorrect
The mysql.user view password_expired column should display the right
result, in sync with whether an account has its password expired or not
For mariadb 10.4+ upgrades before this commit, the mysql.user view needs
to be dropped and recreated to actually make the view display the
correct value for the password_expired column.
Diffstat (limited to 'scripts/mysql_system_tables_fix.sql')
-rw-r--r-- | scripts/mysql_system_tables_fix.sql | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/mysql_system_tables_fix.sql b/scripts/mysql_system_tables_fix.sql index 733ed0ed4c1..ac71edccae9 100644 --- a/scripts/mysql_system_tables_fix.sql +++ b/scripts/mysql_system_tables_fix.sql @@ -824,7 +824,7 @@ IF 'BASE TABLE' = (select table_type from information_schema.tables where table_ DROP TABLE user; END IF// -IF 1 = (SELECT count(*) FROM information_schema.VIEWS WHERE TABLE_CATALOG = 'def' and TABLE_SCHEMA = 'mysql' and TABLE_NAME='user' and DEFINER = 'root@localhost') THEN +IF 1 = (SELECT count(*) FROM information_schema.VIEWS WHERE TABLE_CATALOG = 'def' and TABLE_SCHEMA = 'mysql' and TABLE_NAME='user' and (DEFINER = 'root@localhost' or VIEW_DEFINITION LIKE "%'N' AS `password_expired`%")) THEN DROP VIEW IF EXISTS mysql.user; END IF// |