Bläddra i källkod

Updated database

Andrew Grant 5 månader sedan
förälder
incheckning
fe52edf4e9

+ 1 - 1
src/main/resources/application.properties

@@ -2,7 +2,7 @@ spring.application.name=grants
 server.port=8086
 server.servlet.context-path=/grants
 spring.mvc.format.date=dd-MM-yyyy
-spring.profiles.active=dev
+spring.profiles.active=uat
 logging.level.scot.carricksoftware=trace
 
 

+ 13 - 0
src/main/resources/db/changelog/2025/07/01-01-changelog.sql

@@ -0,0 +1,13 @@
+/*
+ * Copyright (c) 2025.  Andrew Grant Carrick Software. All rights reserved
+ *
+ */
+
+-- liquibase formatted sql
+
+-- changeset apg:1751374417575-1
+ALTER TABLE birth_certificate
+    ADD father_usual_residence_id        BIGINT       NULL,
+    ADD untracked_father_usual_residence VARCHAR(255) NULL;
+
+

+ 11 - 0
src/main/resources/db/changelog/2025/07/01-02-changelog.sql

@@ -0,0 +1,11 @@
+/*
+ * Copyright (c) 2025.  Andrew Grant Carrick Software. All rights reserved
+ *
+ */
+
+-- liquibase formatted sql
+
+-- changeset apg:1751374417575-3
+ALTER TABLE birth_certificate
+    ADD CONSTRAINT FK_BIRTHCERTIFICATE_ON_FATHER_USUAL_RESIDENCE FOREIGN KEY (father_usual_residence_id) REFERENCES place (id);
+

+ 16 - 0
src/main/resources/db/changelog/2025/07/01-03-changelog.sql

@@ -0,0 +1,16 @@
+/*
+ * Copyright (c) 2025.  Andrew Grant Carrick Software. All rights reserved
+ *
+ */
+
+-- liquibase formatted sql
+
+-- changeset apg:1751374845476-1
+ALTER TABLE birth_certificate
+    ADD father_usual_residence_id        BIGINT       NULL,
+    ADD untracked_father_usual_residence VARCHAR(255) NULL;
+
+-- changeset apg:1751374845476-3
+ALTER TABLE birth_certificate
+    ADD CONSTRAINT FK_BIRTHCERTIFICATE_ON_FATHER_USUAL_RESIDENCE FOREIGN KEY (father_usual_residence_id) REFERENCES place (id);
+

+ 2 - 0
src/main/resources/db/changelog/master.xml

@@ -35,6 +35,8 @@
     <include file="/db/changelog/2025/06/27-01-changelog.sql"/>
     <include file="/db/changelog/2025/06/27-02-changelog.sql"/>
     <include file="/db/changelog/2025/06/27-03-changelog.sql"/>
+    <include file="/db/changelog/2025/07/01-01-changelog.sql"/>
+    <include file="/db/changelog/2025/07/01-02-changelog.sql"/>
 
 
 </databaseChangeLog>