Skip to content

Commit 8468db9

Browse files
authored
Merge branch 'main' into add-null-checks-to-summaries
2 parents c8417ce + e46385e commit 8468db9

File tree

1 file changed

+15
-5
lines changed

1 file changed

+15
-5
lines changed
Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<databaseChangeLog xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
2-
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
3-
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-2.0.xsd">
2+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
3+
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-2.0.xsd">
44

55
<changeSet author="Andrej Romanov" id="ADD-GENERATED-BY-SCRIPT-TO-PROFILE-EMAIL-DOMAIN-TABLE">
66
<preConditions onFail="MARK_RAN">
@@ -9,14 +9,24 @@
99
</not>
1010
</preConditions>
1111
<sql>ALTER TABLE profile_email_domain ADD generated_by_script boolean default false;</sql>
12-
</changeSet>
12+
</changeSet>
1313

1414
<changeSet author="Andrej Romanov" id="UPDATE-GENERATED-BY-SCRIPT-BASED-ON-CREATED-DATE" dbms="postgresql">
1515
<sql>UPDATE profile_email_domain SET generated_by_script = true WHERE date_created &lt; '2024-10-28';</sql>
1616
</changeSet>
1717

18-
<changeSet author="Angel Montenegro" id="SET-FALSE-TO-NULL" dbms="postgresql">
18+
<changeSet author="Angel Montenegro" id="SET-FALSE-TO-NULL-VALUES" dbms="postgresql">
1919
<sql>UPDATE profile_email_domain SET generated_by_script = false WHERE generated_by_script is null;</sql>
2020
</changeSet>
2121

22-
</databaseChangeLog>
22+
<changeSet author="Angel Montenegro" id="SET-FIELD-NOT-NULLABLE" dbms="postgresql">
23+
<preConditions onFail="MARK_RAN">
24+
<sqlCheck expectedResult="YES">select is_nullable from information_schema.columns where table_name = 'profile_email_domain' and column_name = 'generated_by_script';</sqlCheck>
25+
</preConditions>
26+
<addNotNullConstraint
27+
columnName="generated_by_script"
28+
tableName="profile_email_domain"
29+
defaultNullValue="false"/>
30+
</changeSet>
31+
32+
</databaseChangeLog>

0 commit comments

Comments
 (0)