09-17-2015 10:38 AM
Solved! Go to Solution.
09-22-2015 02:04 PM
Select Top 1000000 tblADusers.Userdomain,
tblADusers.Username,
tsysAssetRelationTypes.Name As Relation,
tblAssetUserRelations.StartDate As since,
tblAssets.AssetID,
tblAssets.AssetName
From tblADusers
Inner Join tblAssetUserRelations On tblADusers.Username =
tblAssetUserRelations.Username And tblADusers.Userdomain =
tblAssetUserRelations.Userdomain
Inner Join tblAssets On tblAssets.AssetID = tblAssetUserRelations.AssetID
Inner Join tsysAssetRelationTypes On tsysAssetRelationTypes.RelationTypeID =
tblAssetUserRelations.Type
Where tblADusers.Username =@username And tsysAssetRelationTypes.Name In
('used by', 'controlled by')
Order By tblAssets.Userdomain,
tblAssets.Username,
tblAssets.AssetName
09-22-2015 02:04 PM
Select Top 1000000 tblADusers.Userdomain,
tblADusers.Username,
tsysAssetRelationTypes.Name As Relation,
tblAssetUserRelations.StartDate As since,
tblAssets.AssetID,
tblAssets.AssetName
From tblADusers
Inner Join tblAssetUserRelations On tblADusers.Username =
tblAssetUserRelations.Username And tblADusers.Userdomain =
tblAssetUserRelations.Userdomain
Inner Join tblAssets On tblAssets.AssetID = tblAssetUserRelations.AssetID
Inner Join tsysAssetRelationTypes On tsysAssetRelationTypes.RelationTypeID =
tblAssetUserRelations.Type
Where tblADusers.Username =@username And tsysAssetRelationTypes.Name In
('used by', 'controlled by')
Order By tblAssets.Userdomain,
tblAssets.Username,
tblAssets.AssetName
09-22-2015 10:57 AM
09-18-2015 03:55 PM
Select Top 1000000 tblADusers.Userdomain,
tblADusers.Username,
tsysAssetRelationTypes.Name As Relation,
tblAssetUserRelations.StartDate As since,
tblAssets.AssetID,
tblAssets.AssetName
From tblADusers
Inner Join tblAssetUserRelations On tblADusers.Username =
tblAssetUserRelations.Username And tblADusers.Userdomain =
tblAssetUserRelations.Userdomain
Inner Join tblAssets On tblAssets.AssetID = tblAssetUserRelations.AssetID
Inner Join tsysAssetRelationTypes On tsysAssetRelationTypes.RelationTypeID =
tblAssetUserRelations.Type
Where tsysAssetRelationTypes.Name In ('used by', 'controlled by')
Order By tblAssets.Userdomain,
tblAssets.Username,
tblAssets.AssetName
Experience Lansweeper with your own data. Sign up now for a 14-day free trial.
Try Now