Error code 1005, SQL state HY000: Can't create table errno: 150

前端 未结 5 689
生来不讨喜
生来不讨喜 2021-01-01 06:40

I\'m trying to create a table but the script fails as soon as my netbeans errors the first table of DB.

How can this be solved?

CREATE TABLE filmy
(         


        
5条回答
  •  独厮守ぢ
    2021-01-01 07:34

    The code 150 is a foreign key error.

    One of the referenced tables or columns does not exist (yet, maybe later in your script) or doesn't match type/length/collation/charset. Comment them out in turn to see which one.

    Or run separate ALTER TABLE commands after all your CREATEs have run

提交回复
热议问题