简体   繁体   English

MySQL 在 Visual Studio 2019 中生成实体数据 model 时崩溃

[英]MySQL crash while generating entity data model in Visual Studio 2019

When I try to generate the entity models from the existing database the mysqld service crashes.当我尝试从现有数据库生成实体模型时,mysqld 服务崩溃。 This does not occur with MySQL 8.0.20, only with 8.0.21. MySQL 8.0.20 不会出现这种情况,只有 8.0.21 才会出现这种情况。 I was hoping to use the new json features added to the update but this problem is driving me nuts.我希望使用更新中添加的新 json 功能,但这个问题让我抓狂。

MySQL Installed MySQL 已安装

The entity wizard connects ok with the server and show the tables I want to import, when the importing process begin throws an exception "connection lost" and I see the mysqld.exe stopped.实体向导与服务器连接正常并显示我要导入的表,当导入过程开始时抛出异常“连接丢失”并且我看到 mysqld.exe 停止。

The MySQL log show nothing useful except for part of the query generated by the wizard: MySQL 日志显示除了向导生成的部分查询之外没有任何用处:

15:45:58 UTC - mysqld got exception 0xc0000005 ;
Most likely, you have hit a bug, but this error can also be caused by malfunctioning hardware.
Thread pointer: 0x1c9945fcfc0
Attempting backtrace. You can use the following information to find out
where mysqld died. If you see no messages after this, something went
terribly wrong...
7ff7c812f74b    mysqld.exe!?get_full_info@Item_aggregate_type@@IEAAXPEAVItem@@@Z()
7ff7c81228d6    mysqld.exe!??0Item_aggregate_type@@QEAA@PEAVTHD@@PEAVItem@@@Z()
7ff7c83ab288    mysqld.exe!?prepare@SELECT_LEX_UNIT@@QEAA_NPEAVTHD@@PEAVQuery_result@@_K2@Z()
7ff7c841dd0e    mysqld.exe!?resolve_derived@TABLE_LIST@@QEAA_NPEAVTHD@@_N@Z()
7ff7c83d40d6    mysqld.exe!?resolve_placeholder_tables@SELECT_LEX@@QEAA_NPEAVTHD@@_N@Z()
7ff7c83d25aa    mysqld.exe!?prepare@SELECT_LEX@@QEAA_NPEAVTHD@@@Z()
7ff7c83ab191    mysqld.exe!?prepare@SELECT_LEX_UNIT@@QEAA_NPEAVTHD@@PEAVQuery_result@@_K2@Z()
7ff7c841dd0e    mysqld.exe!?resolve_derived@TABLE_LIST@@QEAA_NPEAVTHD@@_N@Z()
7ff7c83d40d6    mysqld.exe!?resolve_placeholder_tables@SELECT_LEX@@QEAA_NPEAVTHD@@_N@Z()
7ff7c83d25aa    mysqld.exe!?prepare@SELECT_LEX@@QEAA_NPEAVTHD@@@Z()
7ff7c83ab191    mysqld.exe!?prepare@SELECT_LEX_UNIT@@QEAA_NPEAVTHD@@PEAVQuery_result@@_K2@Z()
7ff7c841dd0e    mysqld.exe!?resolve_derived@TABLE_LIST@@QEAA_NPEAVTHD@@_N@Z()
7ff7c83d40d6    mysqld.exe!?resolve_placeholder_tables@SELECT_LEX@@QEAA_NPEAVTHD@@_N@Z()
7ff7c83d25aa    mysqld.exe!?prepare@SELECT_LEX@@QEAA_NPEAVTHD@@@Z()
7ff7c832980c    mysqld.exe!?prepare_inner@Sql_cmd_select@@MEAA_NPEAVTHD@@@Z()
7ff7c832942c    mysqld.exe!?prepare@Sql_cmd_dml@@UEAA_NPEAVTHD@@@Z()
7ff7c8325ef5    mysqld.exe!?execute@Sql_cmd_dml@@UEAA_NPEAVTHD@@@Z()
7ff7c822d36d    mysqld.exe!?mysql_execute_command@@YAHPEAVTHD@@_N@Z()
7ff7c822dfc9    mysqld.exe!?mysql_parse@@YAXPEAVTHD@@PEAVParser_state@@@Z()
7ff7c8226eb2    mysqld.exe!?dispatch_command@@YA_NPEAVTHD@@PEBTCOM_DATA@@W4enum_server_command@@@Z()
7ff7c8227e6e    mysqld.exe!?do_command@@YA_NPEAVTHD@@@Z()
7ff7c80726c8    mysqld.exe!?modify_thread_cache_size@Per_thread_connection_handler@@SAXK@Z()
7ff7c93322a1    mysqld.exe!?set_compression_level@Zstd_comp@compression@transaction@binary_log@@UEAAXI@Z()
7ff7c8f3739c    mysqld.exe!?my_thread_join@@YAHPEAUmy_thread_handle@@PEAPEAX@Z()
7fff75851542    ucrtbase.dll!_configthreadlocale()
7fff77ab6fd4    KERNEL32.DLL!BaseThreadInitThunk()
7fff77bfcec1    ntdll.dll!RtlUserThreadStart()

Trying to get some variables.
Some pointers may be invalid and cause the dump to abort.
Query (1c999a99d08): SELECT
`Project7`.`C12` AS `C1`, 
`Project7`.`C1` AS `C2`, 
`Project7`.`C2` AS `C3`, 
`Project7`.`C3` AS `C4`, 
`Project7`.`C4` AS `C5`, 
`Project7`.`C5` AS `C6`, 
`Project7`.`C6` AS `C7`, 
`Project7`.`C7` AS `C8`, 
`Project7`.`C8` AS `C9`, 
`Project7`.`C9` AS `C10`, 
`Project7`.`C10` AS `C11`
FROM (SELECT
`UnionAll3`.`SchemaName` AS `C1`, 
`UnionAll3`.`Name` AS `C2`, 
`UnionAll3`.`ReturnTypeName` AS `C3`, 
`UnionAll3`.`IsAggregate` AS `C4`, 
`UnionAll3`.`C1` AS `C5`, 
`UnionAll3`.`IsBuiltIn` AS `C6`, 
`UnionAll3`.`IsNiladic` AS `C7`, 
`UnionAll3`.`C2` AS `C8`, 
`UnionAll3`.`C3` AS `C9`, 
`UnionAll3`.`C4` AS `C10`, 
`UnionAll3`.`C5` AS `C11`, 
1 AS `C12`
FROM ((SELECT
`Extent1`.`SchemaName`, 
`Extent1`.`Name`, 
`Extent1`.`ReturnTypeName`, 
`Extent1`.`IsAggregate`, 
1 AS `C1`, 
`Extent1`.`IsBuiltIn`, 
`Extent1`.`IsNiladic`, 
`UnionAll1`.`Name` AS `C2`, 
`UnionAll1`.`TypeName` AS `C3`, 
`UnionAll1`.`Mode` AS `C4`, 
`UnionAll1`.`Ordinal` AS `C5`
FROM (
        SELECT /* Funct
Connection ID (thread ID): 18
Status: NOT_KILLED

The manual page at http://dev.mysql.com/doc/mysql/en/crashing.html contains
information that should help you find out what is causing the crash.

Is this a bug or some kind of configuration error on my part?这是我的错误还是某种配置错误?

This proved to be a bug in the new query optimizations, but I was able to find a workaround by disabling some of the optimizations on the server.这被证明是新查询优化中的一个错误,但我能够通过禁用服务器上的一些优化来找到解决方法。

Here is the command I used:这是我使用的命令:

Set global optimizer_switch='derived_merge=off,subquery_to_derived=off,prefer_ordering_index=off,semijoin=off';

Hope it helps until they fix the bug.希望在他们修复错误之前有所帮助。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM