Jeff Rosenberg
Jeff Rosenberg

Reputation: 3572

Can I manually overwrite the Changeset ID?

I'm trying to switch from SVN to TFS, and I'm wondering if there's any way to manually set the TFS Changeset ID to match my SVN Revision number. I have a few internal tools that perform some automated tasks based on the SVN revision, and they're all going to stop working if the revision number changes from 2,050 back down to 1.

I'm sure this isn't really the optimal way to handle these internal processes, but it's working for us and we'll probably only be using these tools for the next 12-18 months, so I don't really want to rewrite them. Any ideas would be appreciated.

Upvotes: 0

Views: 130

Answers (2)

KMoraz
KMoraz

Reputation: 14164

It's controlled by the in tbl_ChangeSet.ChangeSetId field in the collection DB. It's an hack but you should be able to drop the primary key constraint, assign it with any value, and set back the primary key.

A safer approach would be creating a custom Check-In Note ("SVN Revision") for storing the original revision numbers.

Upvotes: 1

Jonathan
Jonathan

Reputation: 7551

I doubt that you get to set TFS changeset IDs. However, usually when migrating between source control systems, you use some tool/script that migrates the history, creating checkins that match the original checkins in content (not in IDs though), and that might set the changeset IDs more to your tools' liking.

Upvotes: 1

Related Questions