Jump to content

Recommended Posts

I just started using Qcodo framework, and ran the codegen. It produced the following error regarding my mysql database:

 

Notice: It is recommended that you add a single-column index on "am_startup.empl

oyee" for the Foreign Key am_startup_ibfk_1

 

I'm not exactly sure what this means? Do I add another column to the table, and name it am_startup_ibfk_1? I already have that column , am_startup.employee indexed. I'm using phpMyAdmin to set up the relations between the tables. I'm just barely grasping foreign keys, so your help would be most appreciated.

 

Link to comment
https://forums.phpfreaks.com/topic/219695-foreign-keys-problem/
Share on other sites

It looks like it's just asking you to create an index on am_startup.employee but if you already have it indexed then I'm not sure why it seems to think it's not.  Might double-check to make sure that your index includes only that column, which is specifically what it's asking for.  If it is correct then it may be a bug in the framework when it checks the database schema.  Someone more familiar with Qcodo may have further insight.

That's what it was. It was including more than the one column in the index. I dropped the relation, dropped the index. added the index back, added the relation back, and codegen. It's not giving the notice any longer. Thanks for your help.

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.