一、背景说明
-
MySQL 版本:8.0.28 | 8.0.40
-
MySQL Workbench 版本:8.0.28
二、报错场景
操作步骤:
-
对于一个有分区的表,查看其表信息,然后点击 “Partitions” 标签页。
-
页面此时没有正常加载分区信息。
-
点击右下角的 “Refresh” ,出现弹窗报错。
报错提示信息:
Unhandled exception: invalid column partition_name for resuleset. Check the log for more details
查看日志文件内容(日志文件路径:%APPDATA%\Roaming\MySQL\Workbench\log\wb.log
):
21:52:40 [ERR][sqlide_tableman_ext.py:show_table:1203]: Error initializing tab partitions: Traceback (most recent call last):
File "K:\MySQLWorkbench\modules\sqlide_tableman_ext.py", line 1200, in show_table
tab.show_table(schema, table)
File "K:\MySQLWorkbench\modules\sqlide_tableman_ext.py", line 854, in show_table
self.refresh()
File "K:\MySQLWorkbench\modules\sqlide_catalogman_ext.py", line 373, in refresh
self.preload_data(self.get_query())
File "K:\MySQLWorkbench\modules\sqlide_catalogman_ext.py", line 367, in preload_data
node.set_string(i, rset.stringFieldValueByName(field) or "" if format_func is None else format_func(rset.stringFieldValueByName(field)))
SystemError: invalid column partition_name for resultset
21:52:43 [ERR][ pymforms]: Unhandled exception in Python code:
21:55:10 [INF][ WQE.net]: Shutting down SQL editor (Local instance MySQL)