Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SQL] Error running SQL/9999-99-99-drop_tables.sql due to physiological_file #8811

Open
zaliqarosli opened this issue Jun 21, 2023 · 1 comment
Assignees
Labels
25.0.0 - Bugs Category: Bug PR or issue that aims to report or fix a bug Language: SQL PR or issue that update SQL code
Milestone

Comments

@zaliqarosli
Copy link
Contributor

zaliqarosli commented Jun 21, 2023

Describe the bug

lorisadmin@copn-dev:/var/www/loris$ mysql < SQL/9999-99-99-drop_tables.sql
ERROR 1451 (23000) at line 27: Cannot delete or update a parent row: a foreign key constraint fails

line 27:

DROP TABLE IF EXISTS `physiological_file`;

I think the issue is because the physiological_file references itself with the ParentID column
edit: not sure what is causing this foreign key constraint fail

To Reproduce
Steps to reproduce the behavior (attach screenshots if applicable):

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

What did you expect to happen?
A clear and concise description of what you expected to happen.

Browser Environment (please complete the following information):

  • OS: [e.g. Plan9, HURD, Oberon, etc]
  • Browser [e.g. chrome, firefox] (note that only these two browsers are supported)
  • Version [e.g. 22]

Server Environment (if known):
Note: We only support the most recent release of LORIS.

  • LORIS Version: [e.g. 22.0.0]
  • Linux distribution and Version: [e.g. Ubuntu 16.04, CentOS 7]
  • MySQL/MariaDB Version: [e.g. MySQL 5.7, MariaDB 10.3]

Additional context
Add any other context about the problem here.

@zaliqarosli zaliqarosli added Category: Bug PR or issue that aims to report or fix a bug Language: SQL PR or issue that update SQL code 25.0.0 - Bugs labels Jun 21, 2023
@CamilleBeau
Copy link
Contributor

This may be fixed, should be tested

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
25.0.0 - Bugs Category: Bug PR or issue that aims to report or fix a bug Language: SQL PR or issue that update SQL code
Projects
Status: PR sent
Development

No branches or pull requests

4 participants