Are circular references acceptable in database?
Consider cities and states. Each city exists within a state. Each state has a capital city. CREATE TABLE city ( city VARCHAR(32), state VARCHAR(32) NOT NULL, PRIMARY KEY (city), FOREIGN KEY (state) REFERENCES state (state) ); CREATE TABLE state ( state VARCHAR(32), capital_city VARCHAR(32), PRIMARY KEY (state), FOREIGN KEY (capital_city) REFERENCES city (city) ); First … Read more