SqlException: Invalid pseudocolumn on synchronisation

HuwJenkinsHuwJenkins Posts: 6 Bronze 1
edited October 9, 2015 4:51AM in SQL Compare 11
Hello,

we are currently running SqlCompare 11.3.0.7 and when we try to run a sync after a compare with a change to a migration script we get the following error.

16:21:28.655|Error |SQL Compare UI |1 |Exception in progress dialog
RedGate.Migrations.Core.Database.TemporaryDatabaseException: <html><body><p>Couldn't create a temporary database on LocalDB. Make sure LocalDB is installed. For more information, see <a href="http://www.red-gate.com/localdb">Downloading and installing LocalDB</a>.</p></body></html&gt ---> System.Data.SqlClient.SqlException: Invalid pseudocolumn "$sys_p2p_cd_id".
Invalid pseudocolumn "$sys_p2p_cd_id".
Invalid pseudocolumn "$sys_p2p_cd_id".
at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose)
at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady)
at System.Data.SqlClient.SqlCommand.RunExecuteNonQueryTds(String methodName, Boolean async, Int32 timeout, Boolean asyncWrite)
at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(TaskCompletionSource`1 completion, String methodName, Boolean sendToPipe, Int32 timeout, Boolean asyncWrite)
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at RedGate.Shared.SQL.ExecutionBlock.BlockExecutor.ExecuteBlock(ExecutionBlock block, IDbConnection connection)
at #Rjmd.#VLfd.ExecuteBlock(SqlConnectionProperties #6Xhd, BlockExecutor #vIc, ExecutionBlock #4OPb)
at #Rjmd.#VLfd.Run(DeploymentScript #8Xhd, SqlConnectionProperties #6Xhd)
--- End of inner exception stack trace ---
at #Rjmd.#VLfd.Run(DeploymentScript #8Xhd, SqlConnectionProperties #6Xhd)
at #Rjmd.#VLfd.Deploy(IDatabaseSchemaProvider`1 #6Xhd, IDatabaseSchemaProvider`1 #7Xhd)
at RedGate.Migrations.Core.Database.DatabaseCopier`1.GetTempCopy(IDatabaseSchemaProvider`1 before, String collation, SQLVersion serverMajorVersion)
at #Cjmd.#Vkqd.#rBqd(Differences #tIc, ICancellable #Mjmd, MigrationActionPlan #sBqd)
at #Cjmd.#Vkqd.#Rkqd(Differences #tIc, ICancellable #Mjmd)
at #8rg.#aYzd.Populate(Differences #tIc, Options #5OPb, Boolean #hkl, ICancellable #Mjmd)
at RedGate.SQLCompare.Engine.Differences.#6Drd(Options #5OPb, ICancellable #Mjmd, Boolean #hkl)
at #8rg.#PC0c.#MPh(Differences #tIc, Difference #6Urc, Options #5OPb, Boolean #hkl, #buG #Mmce)
at #8rg.#1rPb.#MPh(Differences #tIc, Difference #6Urc, Options #5OPb, Boolean #hkl, #buG #Mmce)
at #8rg.#1rPb.#MPh(Differences #tIc, Difference #6Urc, Options #5OPb, Boolean #hkl)
at RedGate.SQLCompare.Common.CompareEngineExecutor.#MPh(Boolean #hkl)
at RedGate.SQLCompare.Common.CompareEngineExecutor.#Y9G()
at RedGate.Shared.Utils.ProgressTasks.ProgressTask.ExecuteSubTasks()
at RedGate.Shared.Controls.ProgressDialogEx.<>c__DisplayClass7.<DoTasks>b__4(Object q)


The database we are trying to sync with is currently set up with peer to peer replication.
If we make no changes to the migration script and just changes to the table then the sync works just fine.
However, as soon as we make a change to the migration script it throw the above error.

Any thoughts?

cheers,

Huw

Comments

  • I switched to just using basic transactional replication with our secondary location just acting as a backup and in this configuration sqlcompare works. It appears that it's only when using peer-to-peer that this problem arises. The column mentioned in the error "$sys_p2p_cd_id" is used by peer-to-peer replication for conflict resolution. So I don't think sql compare should be having anything to do with this column. It is however a big issue for us as we do want to use P2P replication and we should at least be able to generate an upgrade script whilst replication is running which we can't at the moment by the looks of things.

    cheers,

    Huw
Sign In or Register to comment.