Close this search box.
Close this search box.


Converting tables into innodb

The innodb storage engine supports foreign keys in Mysql.

Open your database, and run this query:

ALTER TABLE table_name ENGINE = InnoDB;

Creating foreign keys

Convert both tables into innodb, if they are not already.

View the structure of the table which will have a foreign key. Make the referencing field an INDEX.

Now come back to structure view and click Relation view.

Point your foreign keys to the corresponding column names.

Learning Resources

  • Create foreign key using Phpmyadmin article.