2
0
mirror of https://gitlab.isc.org/isc-projects/kea synced 2025-08-30 21:45:37 +00:00

[#90] Added missing triggers

This commit is contained in:
Tomek Mrugalski
2021-06-08 19:06:27 +02:00
parent 8270921750
commit 5e84f241b3

View File

@@ -326,6 +326,10 @@ ALTER TABLE dhcp6_options
ADD CONSTRAINT fk_dhcp6_options_pool FOREIGN KEY (pool_id) REFERENCES dhcp6_pool (id) ON DELETE CASCADE ON UPDATE CASCADE,
ADD CONSTRAINT fk_dhcp6_options_shared_network FOREIGN KEY (shared_network_name) REFERENCES dhcp6_shared_network (name) ON DELETE CASCADE ON UPDATE CASCADE;
CREATE TRIGGER dhcp6_options_modification_ts_update
AFTER UPDATE ON dhcp6_options
FOR EACH ROW EXECUTE PROCEDURE modification_ts_update();
-- Now create a table for associating defined options with servers.
CREATE TABLE dhcp6_options_server (
option_id BIGINT NOT NULL,
@@ -573,6 +577,10 @@ ALTER TABLE dhcp4_options
ADD CONSTRAINT fk_dhcp4_options_pool FOREIGN KEY (pool_id) REFERENCES dhcp4_pool (id) ON DELETE CASCADE ON UPDATE CASCADE,
ADD CONSTRAINT fk_dhcp4_options_shared_network FOREIGN KEY (shared_network_name) REFERENCES dhcp4_shared_network (name) ON DELETE CASCADE ON UPDATE CASCADE;
CREATE TRIGGER dhcp4_options_modification_ts_update
AFTER UPDATE ON dhcp4_options
FOR EACH ROW EXECUTE PROCEDURE modification_ts_update();
-- Update the schema version number
UPDATE schema_version
SET version = '7', minor = '0';