MySQL error code 1452: Foreign key What's wrong (good long no longer repeat English haha ha)

Source: Internet
Author: User

I see a lot of the same solution here, okay, all the same, here's an article from the Linux commune. Http://www.linuxidc.com/Linux/2012-10/71821.htm, as for my own solution, I first clear the data index, and then delete the record, this time should be able to add foreign keys on the other side (you know what I mean, Is originally from A to B add foreign key, I this to add from B to a foreign key reverse operation the most invincible hahaha, I am still thinking that this operation and what is different, but the result is: successful implementation of the foreign Key Association. Of course, the data must be populated before the foreign keys and indexes are set.

MySQL error code 1452: Foreign key What's wrong (good long no longer repeat English haha ha)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

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.