<?xml version="1.0" encoding="UTF-8"?>
<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.8.xsd">

    <changeSet id="20241030010400" author="daria">
        <preConditions onFail="MARK_RAN">
            <tableExists tableName="activity"/>
            <columnExists tableName="activity" columnName="date"/>
        </preConditions>
        <renameColumn tableName="activity" oldColumnName="date" newColumnName="start_date"/>
        <addColumn tableName="activity">
            <column name="end_date" type="date">
                <constraints nullable="false"/>
            </column>
        </addColumn>
    </changeSet>
</databaseChangeLog>
