Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6681913
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T04:38:39+00:00 2026-05-26T04:38:39+00:00

Problems with MySQL using InnoDB and dropping an unused, foreign key. The foreign key

  • 0

Problems with MySQL using InnoDB and dropping an unused, foreign key. The foreign key references another table’s id. However, I don’t need this field.

I’ve tried removing the fk index, which doesn’t work – says it’s needed in a foreign key contraint. And removing the field, which gives me an error:

1025 – Error on rename of ‘./axis/#sql-ad8_1531’ to ‘./axis/Schedule’ (errno: 150)

The table is currently empty. There are no tables referencing this field. Any ideas on how to get rid of this? Other than creating a new table?

If I’m reading the below error correctly, I can’t drop the column since the fk index is declared. And I can’t drop the index, because the column exists. Chicken & Egg??

LATEST FOREIGN KEY ERROR
111004 17:05:40 Error in foreign key constraint of table axis/Schedule:
there is no index in the table which would contain
the columns as the first columns, or the data types in the
table do not match the ones in the referenced table
or one of the ON … SET NULL columns is declared NOT NULL. Constraint:
,
CONSTRAINT “fk_Schedule_Grp” FOREIGN KEY (“idGrp”) REFERENCES “Grp” (“idGrp”) ON DELETE NO ACTION ON UPDATE NO ACTION
InnoDB: Renaming table axis. to axis.Schedule failed!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T04:38:40+00:00Added an answer on May 26, 2026 at 4:38 am

    You need to use

    ALTER TABLE table_name DROP FOREIGN KEY constraint_name
    

    Here constraint_name is the name of the constraint rather than the index. If you do not know what this is, you can find out by issuing a SHOW CREATE TABLE. It is the identifier that appears after the word CONSTRAINT.

    Edit: From your addition to the question, it looks like you need to issue

    ALTER TABLE table_name DROP FOREIGN KEY fk_Schedule_Grp
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm using the latest EclipseLink version with MySQL 5.5 (table type InnoDB). I'm inserting
I've been using MySQL and I need a column called Status in a table.
I have one MySQL table using the InnoDB storage engine; it contains about 2M
Buried in mySQL syntax and query structure problems once more. I'm currently doing this
I have a table in MySQL 5 (InnoDB) that is used as a daemon
We're using MySQL with InnoDB storage engine and transactions a lot, and we've run
I've exported a mysqldump of a database with InnoDB tables and foreign key relationships
I am using mysql database, innoDB and MyISAM both engines. I want to see
I am using django with mysql (InnoDB) and have the following in my django
I have problems using Mysql with MySQL Connector, I can successfully connect to a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.