SQL - Table Constraints
Consider these tables:
CREATE TABLE parent (id INT PRIMARY KEY);What is the value of
CREATE TABLE child (id INT PRIMARY KEY, parent_id INT, FOREIGN KEY (parent_id) REFERENCES parent(id) ON DELETE SET NULL);
INSERT INTO parent VALUES (1);
INSERT INTO child VALUES (10, 1);
DELETE FROM parent WHERE id = 1;
parent_id in the child row after the delete?