2 jokin132 jokin132 于 2016.03.26 11:12 提问

mysql执行update临时表时崩溃

直接上日志:
thd: 0x1c1a50f0
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...
InnoDB: Thread 9912 stopped in file G:\mysql-6.0.11-alpha-winbuild\mysql-community-nt-6.0.11-alpha-build\storage\innobase\include\sync0sync.ic line 115
InnoDB: Thread 4064 stopped in file G:\mysql-6.0.11-alpha-winbuild\mysql-community-nt-6.0.11-alpha-build\storage\innobase\include\sync0sync.ic line 115
0000000140364105 mysqld.exe!btr_pcur_restore_position()[btr0pcur.c:217]
0000000140305687 mysqld.exe!row_unlock_for_mysql()[row0mysql.c:1546]
00000001402F73C5 mysqld.exe!ha_innobase::unlock_row()[ha_innodb.cc:4243]
000000014015A800 mysqld.exe!evaluate_join_record()[sql_select.cc:16569]
000000014015CBBE mysqld.exe!sub_select()[sql_select.cc:16303]
000000014015DBFC mysqld.exe!do_select()[sql_select.cc:15833]
InnoDB: Thread 3948 stopped in file .\handler\ha_innodb.cc line 2277
0000000140162275 mysqld.exe!JOIN::exec()[sql_select.cc:2468]
00000001401658D1 mysqld.exe!mysql_select()[sql_select.cc:3069]
00000001401D795B mysqld.exe!mysql_derived_filling()[sql_derived.cc:294]
00000001401D77D0 mysqld.exe!mysql_handle_derived()[sql_derived.cc:56]
00000001401D0539 mysqld.exe!mysql_multi_update_prepare()[sql_update.cc:1194]
000000014008CDFC mysqld.exe!mysql_execute_command()[sql_parse.cc:3138]
000000014017D358 mysqld.exe!sp_instr_stmt::exec_core()[sp_head.cc:2929]
000000014017FBD5 mysqld.exe!sp_lex_keeper::reset_lex_and_exec_core()[sp_head.cc:2751]
0000000140181159 mysqld.exe!sp_instr_stmt::execute()[sp_head.cc:2864]
0000000140181816 mysqld.exe!sp_head::execute()[sp_head.cc:1250]
0000000140182884 mysqld.exe!sp_head::execute_procedure()[sp_head.cc:1989]
000000014008ED50 mysqld.exe!mysql_execute_command()[sql_parse.cc:4384]
000000014008FA7A mysqld.exe!mysql_parse()[sql_parse.cc:5942]
0000000140090547 mysqld.exe!dispatch_command()[sql_parse.cc:1051]
000000014009130C mysqld.exe!do_command()[sql_parse.cc:731]
00000001400AF135 mysqld.exe!handle_one_connection()[sql_connect.cc:1146]
000000014047011E mysqld.exe!pthread_start()[my_winthread.c:63]
0000000140500737 mysqld.exe!_callthreadstartex()[threadex.c:348]
000000014050080F mysqld.exe!_threadstartex()[threadex.c:326]
00007FFBCE738102 KERNEL32.DLL!BaseThreadInitThunk()
00007FFBCF12C5B4 ntdll.dll!RtlUserThreadStart()
Trying to get some variables.
Some pointers may be invalid and cause the dump to abort...
thd->query at 000000001C1C0190=update results a left join (

    select b.goodsid,sum(b.qty) as qty,sum(b.money) as money

    from erp_stockin_main a,erp_stockin_detail b

    where a.compid =  NAME_CONST('in_compId',1) 

    and a.dt between  NAME_CONST('v_firstDay',_binary'2016-03-01' COLLATE 'binary') and  NAME_CONST('in_dt',_binary'2016-03-26' COLLATE 'binary')

    and ( NAME_CONST('in_whouse',_utf8'' COLLATE 'utf8_general_ci') != '' or a.billtype != 'MOVE' ) -- 查全部仓库时去掉移库

    and ( NAME_CONST('in_whouse',_utf8'' COLLATE 'utf8_general_ci') = '' or a.whouse =  NAME_CONST('in_whouse',_utf8'' COLLATE 'utf8_general_ci'))

    and a.state = '1' -- 已提交

    and a.billid = b.billid 

    group by b.goodsid

) b on a.goodsid = b.goodsid

set a.inqty = nullif(b.qty,0),

    a.inmoney = nullif(b.money,0)

thd->thread_id=18
thd->killed=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.

补充:日志中InnoDB: Thread 9912 stopped in file G:\mysql-6.0.11-alpha-winbu...在我的文件系统中根本不存在这个文件

Csdn user default icon
上传中...
上传图片
插入图片
准确详细的回答,更有利于被提问者采纳,从而获得C币。复制、灌水、广告等回答会被删除,是时候展现真正的技术了!
其他相关推荐
update 值从临时表取
update table1 a    set id1 =        (select uuid           from table2          where to_number(a.id2) = to_number(id2)            and rownum = 1)  where (no1, decode(no2, '', 'A', no2)) in    
MySQL中Update、select联用操作单表、多表,及视图与临时表的区别
一、MySQL中使用从表A中取出数据来更新表B的内容: 例如:要update表data中的一些列属性,但是修改属性的内容来源是来自表chanpin。SQL语言中不要显示的出现select关键字 update data d,chanpin c set d.zhulei=c.zhulei,d.xiaolei=c.xiaolei,d.fenxiang=c.fenxiang,d.zhuanye
MySQL中的临时表使用方法
当工作在非常大的表上时,你可能偶尔需要运行很多查询获得一个大量数据的小的子集,不是对整个表运行这些查询,而是让MySQL每次找出所需的少数记录,将记录选择到一个临时表可能更快些,然后多这些表运行查询。   当工作在非常大的表上时,你可能偶尔需要运行很多查询获得一个大量数据的小的子集,不是对整个表运行这些查询,而是让MySQL每次找出所需的少数记录,将记录选择到一个临时表可能更快些,然后多这些
mysql 批量更新临时表中的数据
CREATE     PROCEDURE `301`.`useCursor`()         BEGIN   DECLARE msg VARCHAR(255);   DECLARE STOP INT DEFAULT 0;   DECLARE cur CURSOR FOR ( SELECT  `诊断` AS msg FROM `生化信息表_copy`  WHERE `诊断`
mysql 通过存储过程批量更新数据(注意操作用户需要有mysql的创建临时表权限)
批量更新数据库的数据,其中先修改部分字段,然后对存在某些特殊字段的数据集更新其账户名称,其中账户名称用xs_加8位随机数生成. 需要说明的一点,使用临时表需要注意,参考https://www.cnblogs.com/conanwang/p/5844378.html
无法更新临时表的问题
大家帮忙看看这个品牌维护的表单,在VFP中测试可以,一但连编就显示“不能更新临时表”。无论操作添加还是PAGE2的修改,我不知道是怎么回事,高手帮看看,谢谢!!!!表单和所用的表已上传
mysql执行update时出现问题解决
缘由: 我在mysql 中,用了以下语句 UPDATE benben.STUDENT SET SAGE = SAGE+1; 时出现了 Error Code: 1175. You are using safe update mode and you tried to update a table without a WHERE that uses a KEY column To disable 
SQL知识整理一:触发器、存储过程、变量表、临时表
create trigger tr_name on table/view {for | after | instead of } [update][,][insert][,][delete] [with encryption] as {batch | if update (col_name) [{and|or} update (col_name)] }
mybatis动态创建临时表
create temporary table ${tableName} (   id int not null generated by default as identity,   age int not null,   name varchar(255),   primary key (id))         欢迎访问我们的技术交流群425783133
sql触发器(insert,update,delete)
来源:http://blog.sina.com.cn/s/blog_78106bb101014nep.html --insert 触发器 create trigger tri_insert on student  --将要进行更改的表名 for insert  --给表插入一条数据的时候触发 as declare @student_id char(10) --定义一