Why foreign key doesn't update?
问题 I insert data in the column TEMP1.aa (primary key in temp1), but it doesn't import into the TEMP2.cc column (foreign key in TEMP2). Why? I thought if insert data in primary key it automatic insert into foreign key! If this true that if we insert in a primary key, foreign key must be updated? 回答1: A foreign key does not update child references, it only ensures that the value stored in the column already exists in the parent table. But MySQL supports cascading an update, by adding the ON UPDATE