MySQL. Can't create table errno 150

前端 未结 22 1355
广开言路
广开言路 2020-12-01 09:59

I have to create a database with two tables in MySQL, but the script fails with errno 150 (foreign key problem). I double-checked the foreign key fields to be the same on bo

22条回答
  •  借酒劲吻你
    2020-12-01 10:58

    If nothing works, try this:

    The foreign key name is a duplicate of an already existing key. Check that the name of your foreign key is unique within your database. Just add a few random characters to the end of your key name to test for this.

提交回复
热议问题