{"id":646,"date":"2011-09-18T12:29:57","date_gmt":"2011-09-18T17:29:57","guid":{"rendered":"http:\/\/bucktownbell.com\/?p=646"},"modified":"2012-10-14T17:23:47","modified_gmt":"2012-10-14T22:23:47","slug":"referential-integrity-wikipedia-the-free-encyclopedia","status":"publish","type":"post","link":"http:\/\/bucktownbell.com\/?p=646","title":{"rendered":"Referential integrity"},"content":{"rendered":"<blockquote><p><strong>Referential integrity<\/strong> is a property of data which, when satisfied, requires every value of one attribute (column) of a <a title=\"Relation (database)\" href=\"http:\/\/en.wikipedia.org\/wiki\/Relation_%28database%29\">relation<\/a> (table) to exist as a value of another attribute in a different (or the same) relation (table).<sup id=\"cite_ref-0\"><a href=\"http:\/\/en.wikipedia.org\/wiki\/Referential_integrity#cite_note-0\">[1]<\/a><\/sup><\/p>\n<p>For referential integrity to hold in a <a title=\"Relational database\" href=\"http:\/\/en.wikipedia.org\/wiki\/Relational_database\">relational database<\/a>, any field in a <a title=\"Table (database)\" href=\"http:\/\/en.wikipedia.org\/wiki\/Table_%28database%29\">table<\/a> that is declared a <a title=\"Foreign key\" href=\"http:\/\/en.wikipedia.org\/wiki\/Foreign_key\">foreign key<\/a> can contain only values from a parent table&#8217;s <a title=\"Primary key\" href=\"http:\/\/en.wikipedia.org\/wiki\/Primary_key\">primary key<\/a> or a <a title=\"Candidate key\" href=\"http:\/\/en.wikipedia.org\/wiki\/Candidate_key\">candidate key<\/a>. For instance, deleting a record that contains a value referred to by a foreign key in another table would break referential integrity. Some <a title=\"Relational database management system\" href=\"http:\/\/en.wikipedia.org\/wiki\/Relational_database_management_system\">relational database management systems<\/a> (RDBMS) can enforce referential integrity, normally either by deleting the foreign key rows as well to maintain integrity, or by returning an error and not performing the delete. Which method is used may be determined by a referential integrity constraint defined in a <a title=\"Data dictionary\" href=\"http:\/\/en.wikipedia.org\/wiki\/Data_dictionary\">data dictionary<\/a>.<\/p><\/blockquote>\n<p>Via <a href=\"http:\/\/en.wikipedia.org\/wiki\/Referential_integrity\">Referential integrity &#8211; Wikipedia, the free encyclopedia<\/a>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Referential integrity is a property of data which, when satisfied, requires every value of one attribute (column) of a relation (table) to exist as a value of another attribute in a different (or the same) relation (table).[1] For referential integrity &hellip; <a href=\"http:\/\/bucktownbell.com\/?p=646\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[54],"tags":[170,156,261,169],"class_list":["post-646","post","type-post","status-publish","format-standard","hentry","category-programming","tag-data-modeling","tag-databases","tag-definition","tag-relation"],"_links":{"self":[{"href":"http:\/\/bucktownbell.com\/index.php?rest_route=\/wp\/v2\/posts\/646","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/bucktownbell.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/bucktownbell.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/bucktownbell.com\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"http:\/\/bucktownbell.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=646"}],"version-history":[{"count":3,"href":"http:\/\/bucktownbell.com\/index.php?rest_route=\/wp\/v2\/posts\/646\/revisions"}],"predecessor-version":[{"id":7186,"href":"http:\/\/bucktownbell.com\/index.php?rest_route=\/wp\/v2\/posts\/646\/revisions\/7186"}],"wp:attachment":[{"href":"http:\/\/bucktownbell.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=646"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/bucktownbell.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=646"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/bucktownbell.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=646"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}