开发者

MySQL Workbench's treatment of foreign keys

开发者 https://www.devze.com 2022-12-16 17:37 出处:网络
How do I force MySQL Workbench, when using a foreign key, to perform an INSERT to my referenced table before the INSERT to the referencing table. With开发者_如何学Goout the obvious solution of editing

How do I force MySQL Workbench, when using a foreign key, to perform an INSERT to my referenced table before the INSERT to the referencing table. With开发者_如何学Goout the obvious solution of editing the generated SQL by hand?


William,

Unfortunately, MySQL workbench doesn't work this way. You'd have to write the SQL yourself to do this. If you need this often, you might think about writing a stored procedure that handles this for you.

0

精彩评论

暂无评论...
验证码 换一张
取 消