mysql - Error 1215 foreign key constraint -


i'm still new this, have patience while learn rules. i'm having issues mysql script, gives me common 1215 error (cannot create foreign key)

i've checked data types, , foreign keys reference primary keys, , still isn't working.

the script. issue 2 final foreign keys

must declare this:

must declare first foreign key:

create table(id ... , foreignkey int not null,  constraint foreign key(foreignkey) references  table_refered(it primary key));      

// foreignkey- must declare first column , , after declare foreign key luck.


Comments

Popular posts from this blog

aws api gateway - SerializationException in posting new Records via Dynamodb Proxy Service in API -

asp.net - Problems sending emails from forum -