EnVisageOnline/Main/Database/Scripts/20160302/01_Del_Allocations4Inactive...

9 lines
430 B
Transact-SQL
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

USE [EnVisage]
GO
DELETE FROM PeopleResourceAllocation
WHERE Id IN
(SELECT A.Id FROM PeopleResourceAllocation A
INNER JOIN PeopleResource B ON (B.Id = A.PeopleResourceId)
WHERE B.IsActiveEmployee = 0)
GO