1. When designing the table, please select InnoDB as the engine in the options, because InnoDB provides transaction support and advanced database functions such as foreign keys.
Related recommendations: "Navicat for mysql graphic tutorial"
2. Then create a foreign key in a table, Select the "Foreign Key" tab, enter the name of the referential integrity, select which attribute is the foreign key, select the primary key in which table as the foreign key, and so on. Then click Save. Note that if a problem occurs at this time, you can check whether the primary key and foreign keys are of the same type. If the primary key and foreign keys are both numerical, check the unsigned check box in the design table.
3. You’re done.
The above is the detailed content of What should I do if Navicat cannot save foreign keys set up?. For more information, please follow other related articles on the PHP Chinese website!