<?xml version="1.0" encoding="utf-8"?>
<databaseChangeLog
    xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
    xmlns:ext="http://www.liquibase.org/xml/ns/dbchangelog-ext"
    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-latest.xsd
                        http://www.liquibase.org/xml/ns/dbchangelog-ext http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-ext.xsd">

    <!--
        Alter the entity InputDataUpload.
        Remove relation with period_version.
    -->
    <changeSet id="20241110131000-1" author="omg">
    	<!-- Step 1: Drop the foreign key constraint -->
    	<dropForeignKeyConstraint 
        	baseTableName="input_data_upload" 
        	constraintName="fk_input_data_upload__period_version_id"/>
        
        <!-- Step 2: Drop the column -->
        <dropColumn columnName="period_version_id"
                    tableName="input_data_upload" >
        </dropColumn>
    </changeSet>
</databaseChangeLog>
