Answer the question
In order to leave comments, you need to log in
Why can't create table tablename (errno: 150 "Fore ign key constraint is incorrectly formed)" error when creating a foreign key?
Hello... I'm trying to add foreign keys to a table, and for some reason the error is:
Can't create table tablename (errno: 150 "Fore ign key constraint is incorrectly formed)
The key creation query itself looks like this
ALTER TABLE data_nav_toogle_one_way ADD CONSTRAINT fk_markup_ow FOREIGN KEY (`data_nav_ow_id`) REFERENCES `data_nav_toogle_one_way` (id) ON DELETE CASCADE ON UPDATE CASCADE
what could be wrong?
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question