Files
gitlab-notification/gitlab-app/src/main/resources/liquibase/v.2.0.0/2024-09-03-add-group-notify.xml

35 lines
1.5 KiB
XML

<databaseChangeLog
xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-4.17.xsd">
<changeSet id="2024-09-03-add-column-telegram-username" author="mstruchkov">
<addColumn tableName="person">
<column name="telegram_username" type="varchar"/>
</addColumn>
</changeSet>
<changeSet id="2024-09-03-add-column-telegram-username-2" author="mstruchkov">
<dropColumn tableName="person">
<column name="telegram_username"/>
</dropColumn>
<createTable tableName="person_telegram">
<column name="id" type="int">
<constraints nullable="false" primaryKey="true"/>
</column>
<column name="telegram_username" type="varchar">
<constraints nullable="false"/>
</column>
</createTable>
</changeSet>
<changeSet id="2024-09-03-add-link-for-telegram-username" author="mstruchkov">
<addForeignKeyConstraint baseTableName="person"
baseColumnNames="id"
constraintName="fk_person_telegram_id_person_id"
referencedTableName="person"
referencedColumnNames="id"
deleteCascade="true"/>
</changeSet>
</databaseChangeLog>