在我的SQL中添加外键 [英] adding foreign key in my sql
本文介绍了在我的SQL中添加外键的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想在mysql中添加外键,但是我必须为此编写查询.如果我直接创建外键,则仅创建索引,但不创建外键,有人对我如何直接添加外键有任何想法吗?使用工具箱键.
我正在通过XAMPP和Navicat使用mysql,我想直接创建外键而不编写查询.
感谢
i want to add foreign key in mysql ,but i have to write query for that.If i am directly create foreign key then only indexes are create,but not foreign key ,can anybody have any idea regarding how i directly add foreign key using toolbox.
I am using mysql through XAMPP and Navicat ,and i want to create foreign key directly without writing query.
thanks
推荐答案
尝试以下操作:
mysql_create_foreign_key_contraints [ ^ ]
foreign-key-constraints [
try these:
mysql_Create_foreign_key_contraints[^]
foreign-key-constraints[^]
hope it helps :)
这篇关于在我的SQL中添加外键的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文