Do you absolutely need foreign keys in a database?

后端 未结 11 987
遥遥无期
遥遥无期 2021-02-12 20:31

I was wondering how useful foreign keys really are in a database. Essentially, if the developers know what keys the different tables depend on, they can write the queries just

11条回答
  •  我在风中等你
    2021-02-12 21:11

    You said

    but say for example, the programmers do a good job of preserving data integrity

    The expression you were looking for is, "I'm 100% certain that every programmer and every database administrator will manually preserve data integrity perfectly no matter what application touches this database, no matter how complex the database becomes, from now until the time it's decommissioned."

提交回复
热议问题