Breaking News: Grepper is joining You.com. Read the official announcement!
Check it out

SQLSTATE[HY000]: General error: 1215 Cannot add foreign key constraint

Lokesh003 answered on February 28, 2022 Popularity 9/10 Helpfulness 5/10

Contents


More Related Answers

  • SQLSTATE[23000]: Integrity constraint violation: 19 FOREIGN KEY constraint failed
  • General error: 1215 Cannot add foreign key constraint laravel
  • SQLSTATE[23000]: Integrity constraint violation: 4025 CONSTRAINT `categories.name` failed for `apolonia_db`.`categories`
  • error code 1215 cannot add foreign key constraint
  • SQLSTATE[HY000]: General error: 1005 Can't create table `laravel`.`users` (errno: 150 "Foreign key constraint is incorrectly formed") (SQL: alter table `users` add constraint `users_role_id_foreign` foreign key (`role_id`) references `role` (`id`))
  • sqlstate[hy000]: general error: 1005 can't create table (errno: 150 "foreign key constraint is incorrectly formed")
  • SQLSTATE[23000]: Integrity constraint violation: 1452 Cannot add or update a child row: a foreign key constraint fails (`apolonia_db`.`shops`, CONSTRAINT `shops_parent_pharmacy_id_foreign` FOREIGN KEY (`parent_pharmacy_id`) REFERENCES `shops` (`id`))
  • fix when i tried to import a table in mysql it just returns me ' ERROR 1215 (HY000): Cannot add foreign key constraint "
  • SQLSTATE[HY000]: General error: 1005 Can't create table ``.`labels` (errno: 150 "Foreign key constraint is incorrectly formed") (SQL: alter table `labels` add constraint

  • SQLSTATE[HY000]: General error: 1215 Cannot add foreign key constraint

    1
    Popularity 9/10 Helpfulness 5/10 Language sql
    Source: Grepper
    Tags: add key sql
    Link to this answer
    Share Copy Link
    Contributed on Feb 28 2022
    Lokesh003
    0 Answers  Avg Quality 2/10


    X

    Continue with Google

    By continuing, I agree that I have read and agree to Greppers's Terms of Service and Privacy Policy.
    X
    Grepper Account Login Required

    Oops, You will need to install Grepper and log-in to perform this action.