Migration script fails due to column rename
Tom_Philbrick
Posts: 10 New member
Hello,
My refresh is failing with a March 2018 migration script that is compiling against a table where I have renamed a column. 1. I cloned a new copy of all code down from source control.
2. Ran a refresh to a new db via SQL change automation
3. Ran Redgate Sync V13 to get some db changes moved to my local db SQL automation just created (this is where the column got renamed)
4. I think I did a refresh to start to create a new migration script for the changes to move back up to our Azure envir. for build and release.
The error occurs on my local instance of the db, below is the reported error.
Thanks,
-Tom
My refresh is failing with a March 2018 migration script that is compiling against a table where I have renamed a column. 1. I cloned a new copy of all code down from source control.
2. Ran a refresh to a new db via SQL change automation
3. Ran Redgate Sync V13 to get some db changes moved to my local db SQL automation just created (this is where the column got renamed)
4. I think I did a refresh to start to create a new migration script for the changes to move back up to our Azure envir. for build and release.
The error occurs on my local instance of the db, below is the reported error.
Thanks,
-Tom
***** EXECUTING MIGRATION "Migrations\0022_20180323-0633_thomas.philbrick.sql", ID: {6a2f0311-5068-47a7-9683-1b054c634aa9} *****
Creating [Submitter].[CreateSubmitter]
Creating [Submitter].[ReadSubmitter]
Msg 207, Level 16, State 1, Server D1710506, Procedure ReadSubmitter, Line 29
Invalid column name 'ApplicationDate'.
Msg 207, Level 16, State 1, Server D1710506, Procedure ReadSubmitter, Line 29
Invalid column name 'ApplicationDate'.
Tagged:
Best Answer
-
Andrea_Angella Posts: 66 Silver 4Have you managed to solve the issue? You can find more information about script verification here https://documentation.red-gate.com/sca3/developing-databases-using-sql-change-automation/validating-change-scripts/script-verification
If this does not help, I invite you to contact support at support@red-gate.com so we can take a look at your scripts and help you to solve the problem.
ThanksAndrea Angella
Lead Software Engineer | Red Gate
Website: www.productivecsharp.com
Twitter: @angella_andrea
Answers
2018-12-13T17:58:11.0912894Z Validating Deployment Scripts...
2018-12-13T17:58:11.1347190Z Ensuring Shadow database is up-to-date
2018-12-13T17:58:11.1413407Z Building Shadow deployment script...
2018-12-13T17:58:11.4837798Z Deploying Shadow database...
2018-12-13T17:58:20.2310016Z ##[error]TxSure Solution\TxSureStaging\Migrations\0022_20180323-0633_thomas.philbrick.sql(0,0): Error : An error occurred while attempting to verify project scripts:
Msg 207, Level 16, State 1, Server TXSUREDEV-SQL01, Procedure ReadSubmitter, Line 29
Invalid column name 'ApplicationDate'.