Unable to import after deploy - Pending Migrations still found - blank list

Steps:
Create baseline from Environment A (prod)
Create migration based on A->Environment B (QA environment)
Deploy to new DB C (development environment), which now is same as B (deploy is successful, all tables are updated)
Any changes to DB C are not able to be imported into a new migration script.

Error is: Pending Migrations have been found, but the list is blank, and I'm not sure where else I can check. Deleting/Recreating/Redeploying to C doesn't do anything.

I've deployed to C from both Visual Studio and Octopus. I've created C both on localdb and a sql server instance, but the same issue happens.

I do manually remove the extra logins, roles, and schemas manually from the baseline - I can't deploy those in C (cross domain)

Answers

  • Eddie DEddie D Posts: 1,780 Rose Gold 5
    Hi, thank you for your forum post.
    I suspect that your manual modification of your migration script may have changed the hash of the script, so it's not showing up as the same migration.



    Can you please get some extra debugging info by performing the following steps?
    1. Close Visual Studio.
    1. Edit the following file in notepad: C:\Program Files (x86)\MSBuild\SQLChangeAutomationl\logging.config
    1. Change the log level attribute to DEBUG and save the file.
    1. Open the solution in Visual Studio and click "Import & Generate Script" in the DBSync tool.
    1. Send me the following log file: %LocalAppData%\Red Gate\Logs\SQL Change Automation\VS\SQL Change Automation-VS.log
    Many Thanks
    Eddie


    Eddie Davis
    Senior Product Support Engineer
    Redgate Software Ltd
    Email: support@red-gate.com
  • rswickerrswicker Posts: 3 New member
    Will do, quick question : how can I safely remove roles and schemas from the baseline? 
  • rswickerrswicker Posts: 3 New member
    I updated the logging, ran through my steps again and it worked fine. No idea (I swear I've been through this multiple times previously :) ). Will keep updated in the thread if this pops up again.
  • Eddie DEddie D Posts: 1,780 Rose Gold 5
    Hi, thank you for your reply and excellent news all is now working.

    Please either update this post or submit a support request via the Support Portal and click the 'Submit a request' button.

    Many Thanks
    Eddie
    Eddie Davis
    Senior Product Support Engineer
    Redgate Software Ltd
    Email: support@red-gate.com
Sign In or Register to comment.