<%
Class Migration_11_Alter_Tables_For_Relations_FK
    Public Migration

    Public Sub Up
        Migration.Do "ALTER TABLE [InkjetRecords] ADD CONSTRAINT [KitInkjetRecords]" &_
                    " FOREIGN KEY ( [KitID] )" &_
                    " REFERENCES [Kit] ( [ID] )" &_
                    " ON UPDATE CASCADE" &_
                    " ON DELETE CASCADE;"
       
        Migration.Do "ALTER TABLE [KitLabels] ADD CONSTRAINT [KitKitLabels]" &_
                    " FOREIGN KEY ( [KitID] )" &_
                    " REFERENCES [Kit] ( [ID] )" &_
                    " ON UPDATE CASCADE" &_
                    " ON DELETE CASCADE;"
End Sub
    
    Public Sub Down
        Migration.Do "ALTER TABLE [InkjetRecords] " &_
                    "DROP CONSTRAINT [KitInkjetRecords];"
        Migration.Do "ALTER TABLE [KitLabels] " &_
                    "DROP CONSTRAINT [KitKitLabels];"
    End Sub
End Class
 Migrations.Add "Migration_11_Alter_Tables_For_Relations_FK"
 %>