How to solve TFS error TF246021 and SQL Server error 500200 while checking in?

旧城冷巷雨未停 提交于 2019-11-30 17:17:51

This seems to be related to the workspace. I had this problem on one workspace but was able to perform the source control operation that triggered the error (rollback a previous rollback) in a different workspace without any problems.

Recreating your workspace might be a solution.

My solution was to exclude the culprit and check in the rest.
I then checked in the culprit.

( If you have a gated checkin you might have to turn that off first. )

I suspect that somehow the items in the change set use the same ID twice, so the first INSERT is fine but the second will cause the violation. However, since they're in the same transaction, the first INSERT is rolled back and you don't see anything in tbl_PendingDelta afterwards.

See http://connect.microsoft.com/VisualStudio/feedback/details/693450/tfs-2010-violation-of-primary-key-constraint-pk-tbl-pendingdelta for another example of this issue.

I think you should take this up with Microsoft Product Support Services.

I had something similar happen. Previously I had rolled back some changes and was reintroducing those changes in the solution and project files again with the same name. The problem that I found was a sql script rename was not in the Sql.proj file and I needed to add it and then close the solution to accept the changes to the proj file. Once I corrected the rename, made sure that it was in the project file, then I could check it in.

I renamed my workspace folder (the top level containing $tf) then did a get latest on the branch I wanted, then the unshelve worked.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!