#Foreign key constraint is incorrectly formed when create files field

1 messages · Page 1 of 1 (latest)

magic bane
#

{
"errors": [
{
"message": "alter table SLA_files add constraint sla_files_directus_files_id_foreign foreign key (directus_files_id) references directus_files (id) on delete SET NULL - ER_CANT_CREATE_TABLE: Can't create table p_db.SLA_files (errno: 150 "Foreign key constraint is incorrectly formed")",
"extensions": {
"code": "INTERNAL_SERVER_ERROR"
}
}
]
}

tawny hillBOT
#

Thanks for posting! This is a community powered server, so you may or may not get an answer based on available help and expertise. To increase your chances of somebody being able to help you, please make sure your question includes the following:

  • An explanation of exactly what you're trying to achieve.
  • Any and all related code or previous attempts.
  • The exact issue or error you are facing.
  • Any screenshots if applicable.

When you're done with this thread, please close it.

(If you have a support agreement and need help, please contact the core team via email.)

magic bane
#

alter table junction_directus_users_files add constraint junction_directus_users_files_directus_users_id_foreign foreign key (directus_users_id) references directus_users (id) on delete SET NULL"