Why does MYSQL cascade update fail? Any advice?
Adolph
Adolph 2018-06-21 17:56:33
0
0
1481

use my_foreign;

create table myforeign2(

id int primary key auto_increment,

name varchar(20) not null,

c_id int ,

foreign key(c_id) references my_class.myclass(id) on delete set null on update cascade

);

use my_class;

update myclass set id =4 where id = 3;

select * from myclass;

use my_foreign;

select * from myforeign2;

queried The results are not updated

Adolph
Adolph

reply all (0)
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!