/ Published in: SQL
Sometimes it is just more convenient to query the db. Returns Pending changes with local path. Have not investigated what lock status translates to.
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
USE TfsVersionControl SELECT DISTINCT DisplayName AS userName ,wksp.WorkspaceName,wksp.LastAccessDate, pc.TargetChildItem AS Item, pc.TargetParentPath AS tfspath, REPLACE(lv.LocalItem,'>','') AS localFile, LOCK.LockType,LOCK.LockStatus, pc.PendingChangeId,pc.PendingCommand,pc.VersionFrom FROM tbl_identity AS u JOIN dbo.tbl_Workspace wksp ON u.Identityid = wksp.OwnerId JOIN dbo.tbl_PendingChange pc ON pc.WorkspaceId = wksp.WorkspaceId JOIN dbo.tbl_Lock LOCK ON LOCK.LockStatus = pc.LockStatus JOIN dbo.tbl_LocalVersion lv ON pc.ItemId = lv.ItemId AND wksp.WorkspaceId = lv.WorkspaceId WHERE wksp.WorkspaceName = 'Myworkspace'