Folder History Incorrect

If you are having a problem using Vault, post a message here.

Moderator: SourceGear

Post Reply
Justin
Posts: 7
Joined: Tue Jun 01, 2004 2:08 pm

Folder History Incorrect

Post by Justin » Tue Jun 01, 2004 2:16 pm

We just purchased Vault and upgraded a source safe database, everything is runnig great except the folder history seems broken or incorrect.

I posted here because I am not sure if it's realted to VSS conversion or just a bug.

Basically the file versions in the various histories are off and I cant seem to retreive the folder as it was at that point in time. Instead it seems to get the latest version except for the file the triggered the version. also the version numbers seem to be based on file then date instead of date/file as you would think. (probably form how it was imported)

If this is due to conversion, is there any way to get all the files in a folder as they where on a specific date instead of based on folder version?

Thanks,

Justin

Justin
Posts: 7
Joined: Tue Jun 01, 2004 2:08 pm

Post by Justin » Tue Jun 01, 2004 2:47 pm

After some testing looks like its most likely a conversion issue, new checkins seems to make folders version with the correct versions in them for that point in time.

Is this a known VSS conversion issue? If so it would have been nice if it was mentioned in the help or in a faq.

Also as I said is there a workaround, like simple a way to do point in time based on date or the checkin of a file? I believe this is how VSS did it since it didnt really have folder versions, it just found all the others versions based on date.

Thanks,

Justin

jeremy_sg
Posts: 1821
Joined: Thu Dec 18, 2003 11:39 am
Location: Sourcegear
Contact:

Post by jeremy_sg » Tue Jun 01, 2004 3:42 pm

Justin,

You are correct that this is a import issue. Because VSS doesn't have folder versions, the import will create the folder structure in Vault and import each file, creating a new Vault version for every VSS version. You should be able to use Vault's history query to query a folder for all of the file versions underneath it that have a certain date, just bind your query to that start and end date.

Justin
Posts: 7
Joined: Tue Jun 01, 2004 2:08 pm

Post by Justin » Wed Jun 02, 2004 11:36 am

So is there a way to get all the versions in a folder as of a specfic date?

Doesnt look like there is, Sure I can run a history query but there is no way to do gets for everything in the query results is there, only one at a time?

Also needs to be more than a transaction on a date, it would be a query of all file versions as of a date, so bascially the last checkin on or before a given date then do a get on the all the results?

Seems like this kind of thing could have been done on VSS import to create the folder versions, did the vss api not expose a way to get everything else in the folder as of a date or perhaps it was too slow for import process? The VSS client sure did since it didnt have folder versions but could get point in time versions of a folder.

Perhaps I can look into writing my own sql query to find the file versions on a date and then use the api to do get on them so we can go back if we need to.

Thanks,

Justin

dan
Posts: 2448
Joined: Wed Dec 17, 2003 5:03 pm
Location: SourceGear
Contact:

Post by dan » Wed Jun 02, 2004 11:56 am

I can't speak to the import issues, but you can get an entire folder as of a certain date. In the history query on a folder, choose to view folder history by version, and then choose the folder version from there, and press the Get Tree button to retrieve the tree as of that folder version.

Justin
Posts: 7
Joined: Tue Jun 01, 2004 2:08 pm

Post by Justin » Wed Jun 02, 2004 12:40 pm

Dan,

Sorry but that is the primary issue here, since the folder history is messed up from VSS import, if I choose a older version of a folder on a date and do a get tree, it gets *latest* versions of every file except the one that triggered the folder version.

Nothing explains better than a screen shot attached is an example of the Folder version list notice ver 381 is 2/26/2004 notice the view tree of it has newer files in it than 2/26/2004. So if I do a get tree on this the project is fubar.

Justin
Attachments
Folder Versions.JPG
Folder Versions.JPG (134.58 KiB) Viewed 8925 times
View Tree.JPG
View Tree.JPG (88.67 KiB) Viewed 8925 times

jeremy_sg
Posts: 1821
Joined: Thu Dec 18, 2003 11:39 am
Location: Sourcegear
Contact:

Post by jeremy_sg » Wed Jun 02, 2004 12:55 pm

Justin,

As I said above, you are correct. This is a limitation due to the way that we do the VSS Import. There is no easy way in Vault to reconstruct the structure at a moment in time.from VSS. I've done some experimentation with the Vault history, but that won't do what you want because the history query will only show the changes that happened during that time, not the versions that were current as of the time.

If you want, I can work with you to develop a small ClientAPI app that will download the file versions that match a certain date. This would let you reconstruct the folder as of a moment in time.

I want to restate for anyone who just glances over this thread: This only applies to imported VSS history. Vault versions its folders, so you can always use the sequence dan described above to view the tree for a specific transaction in Vault.

Justin
Posts: 7
Joined: Tue Jun 01, 2004 2:08 pm

Post by Justin » Fri Jun 04, 2004 1:42 pm

You guys ever thought about making a sql query to fix the history, shouldnt be too difficult, it would find moddate of the file that triggered the folder version in the vss import and modify all the other files versions in the history to the last verion up to that date?

I have attached a sample I made that finds the correct file versions given a objverid of the folder version which would a starting point for updating the tblfolderentries to the correct verions.

Note this query would only work well on folder version that contain 1 file checkin in the change set, which is what it looks like all vss imported folders versions have.

Justin
Attachments
VSS Flder History Fix.txt
(1.09 KiB) Downloaded 907 times

sven

Post by sven » Mon Sep 06, 2004 7:41 am

I was able to get the versions of a specific date by opening the history of each single file and the the latest version below the date I want the folder to be. So the GUI can do such a job VERY easy - it can simply do what I did - recursively, in a loop without forcing me to do it manually.

I think for moving from vss to VAULT, this is an essential feature - isn't it?

Post Reply