Error Code: 1175. You are using safe update mode and you tried to update a table without a WHERE,1175tried

來源:互聯網
上載者:User

Error Code: 1175. You are using safe update mode and you tried to update a table without a WHERE,1175tried

1 錯誤描述

19:15:34call sp_store_insert(90)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 safe mode, toggle the option in Preferences -> SQL Editor and reconnect.0.093 sec

2 錯誤原因

CREATE DEFINER=`root`@`localhost` PROCEDURE `sp_store_insert`(in score int)BEGIN create temporary table if not exists temp_student(     id int(6) primary key,     name varchar(20) );  delete from temp_student;  insert into temp_student(id,name)  select t.id,t.name from t_computer_stu t where t.score > score; END

call sp_store_insert(90);

3 解決辦法

相關文章

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.