Problems after upgrading to SQL Compare 13 from 10.

I get the error below when I run SQL Compare after upgrading to the latest version (13 from 10). I also updated Source Control from 3.7 to 5 and have upgraded our migration scripts. (It seems like the the error has something to do with one of the migration scripts).

Error: Comparison of '.' and '.' failed: 2017-11-28-091155-u9-user could not
14:12:52 satisfy pre-state for 2017-11-28-091223-ua-auto on one or more of:
14:12:52 Comparison of '.' and '.' failed: 2017-11-28-091155-u9-user could not satisfy pre-state for 2017-11-28-091223-ua-auto on one or more of:
14:12:52 RedGate.Legacy.CommandLine.FatalExecutionException
14:12:52 vid RedGate.SQLToolsCommandLine.CommandProcessor.FatalExceptionHelper(String message, Exception ex)
14:12:52 vid RedGate.SQLToolsCommandLine.CommandProcessor.ProcessThreadException(Exception e)
14:12:52 vid RedGate.SQLToolsCommandLine.CommandProcessor.ProcessThreadException()
14:12:52 vid RedGate.SQLToolsCommandLine.CommandProcessor.RunComparison()
14:12:52 vid RedGate.SQLToolsCommandLine.CommandProcessor.ProcessCommands()
14:12:52 vid RedGate.SQLCompare.CommandLine.CommandProcessor.ProcessCommands()
14:12:52 vid RedGate.SQLToolsCommandLine.CommandProcessor.Run()
14:12:52 Caused by:
14:12:52 2017-11-28-091155-u9-user could not satisfy pre-state for 2017-11-28-091223-ua-auto on one or more of:
14:12:52 RedGate.Database.Helpers.PartialSchemas.Conflicts.ConflictingMigrationException
14:12:52 vid RedGate.Database.Helpers.PartialSchemas.GitRepository.Merge(CommitRef id, FileMergeStrategy fileMergeStrategy, IEnumerable`1 fileOverrides)
14:12:52 vid RedGate.Database.Helpers.PartialSchemas.GitRepositoryBuilder.MergeAndCommit(CommitRef idToMerge, CommitInfo newCommitInfo, FileMergeStrategy fileMergeStrategy)
14:12:52 vid RedGate.Database.Migrations.Synchronizer.Deployment.BlockStateRepositoryBuilder.MergeAndCommitBlock(IBlockId blockId, Boolean acceptsConflicts, CommitInfo newCommitInfo)
14:12:52 vid RedGate.Database.Migrations.Synchronizer.Deployment.BlockHistoryBuilder.MergeAndCommitBlock(IBlockId blockId, CommitInfo newCommitInfo, CommitRef tagForPreviousBlock)
14:12:52 vid RedGate.Database.Migrations.Synchronizer.Deployment.BlockHistoryBuilder.Rebase(List`1 blockIds)
14:12:52 vid RedGate.Database.Migrations.Synchronizer.Deployment.BlockHistoryBuilder.SetOrder(IEnumerable`1 orderedBlocks)
14:12:52 vid RedGate.Database.Migrations.Synchronizer.Deployment.DeploymentModelBuilder.AddDriftedTargetToModel(BlockHistoryBuilder blockHistoryBuilder, IDirectoryInfoWrapper targetDatabase, IEnumerable`1 alreadyDeployedSourceBlocks, IEnumerable`1 blocksToDeploy)
14:12:52 vid RedGate.Database.Migrations.Synchronizer.Deployment.DeploymentModelBuilder.CreateDeploymentModel(IScriptsFolder sourceScriptsFolder, IDirectoryInfoWrapper targetDatabase, IEnumerable`1 blocksInSource, IEnumerable`1 alreadyDeployedSourceBlocks, IList`1 blocksToDeploy, BlockMetadata openBlockMetadata)
14:12:52 vid RedGate.Database.Migrations.Synchronizer.Deployment.Planner.GenerateOrderedDeploymentPlans(IScriptsFolder sourceScriptsFolder, IScriptsFolder targetDatabase, IDifferenceFilterer differenceFilterer)
14:12:52 vid RedGate.Database.Migrations.Synchronizer.Deployment.DeploymentScriptGenerator.GenerateDeploymentScript(IScriptsFolder sourceScriptsFolder, IScriptsFolder targetScriptsFolder, IDifferenceFilterer differenceFilterer)
14:12:52 vid RedGate.SQLToolsUI.MigrationBlocks.MigrationBlocksEngineWrapper.BuildDeploymentScript(IDirectoryInfoWrapper , Database , DeploymentOptions , Differences , IDataSource )
14:12:52 vid RedGate.SQLCompare.Common.CompareEngineExecutor.GenerateMigrationDeploymentScript()
14:12:52 vid RedGate.SQLCompare.Common.CompareEngineExecutor.<CreateSQLFromDependencies>b__173_0()
14:12:52 vid FurHelper.FurUtils.RunOperationWithFur[T](IFur fur, FeatureEventType eventType, FeatureEventType failedEventType, Func`1 operation)
14:12:52 vid FurHelper.CreateSqlFur.RunDeploymentScriptCreationOperation[T](IFur fur, Func`1 operation)
14:12:52 vid RedGate.SQLCompare.Common.CompareEngineExecutor.CreateSQLFromDependencies()
14:12:52 vid RedGate.SQLCompare.CommandLine.CommandLineCompareEngineExecutor.CreateSQLFromDependencies()
14:12:52 vid RedGate.Legacy.ProgressTasks.ProgressTask.ExecuteSubTasks()
14:12:52 vid RedGate.Legacy.ProgressTasks.SimpleProgressTaskExecutor.DoTasks()

Any clues?

Regards/Per
Tagged:

Answers

  • I agree it appears to be migration script related - that error is shown when the Migrations feature detects conflicts while trying to merge changes. The strange part is that it would normally list conflicting files after the "one or more of:" message.

    The reason you are only seeing this now would be that SQL Compare 10 and SOC 3.7 used an earlier implementation of the migrations feature. There's some more info on the upgrade process here which you might find helpful: https://forum.red-gate.com/discussion/82031/upgrading-from-3-x-to-6
    Software Developer
    Redgate Software
  • Hello and thanks for the reply.

    Yes I'm the one who posted the question you linked to. I followed the steps that was recommended and was able to upgrade the migration scripts. But now I don't know what to do since I have no idea what that error message means or how to fix the problem.

    Any suggestions are greatly appreciated. I've created a support ticket for this but haven't gotten any replies yet.

    Regards/Per
  • saulcruzsaulcruz Posts: 19 Bronze 1
    How did you fix this problem? 
Sign In or Register to comment.