navicat+MySQL设置外键MySQL “Cannot add or update a child row: a foreign key constraint fails”

MySQL “Cannot add or update a child row: a foreign key constraint fails” MySQL“无法添加或更新子行:外键约束失败” 意思就是本表的外键 在另一表中没有数据 需要先迁移数据 举例: 需要seller表中sellerId作为外键 对应到assert表中的sellerId主键 如图 先把数据都弄成一致 这样就可以再取设置外键就
相关文章
相关标签/搜索