In 这个结构是对还是错,这给了我错误
SELECT TblProjectResources.UserId
FROM TblTasks,TblProjectResources
WHERE TblTasks.ProjectId=TblProjectResources.ProjectId
AND TblTasks.TaskId=@TaskId AND TblProjectResources.IsRemoved=0
AND TblProjectResources.UserId IN(
(SELECT UserId
FROM TblProjectResources
WHERE IsRemoved=0
AND ProjectApproval=1
AND ProjectId=@ProjectId)
or
(SELECT TblAssignments.AssigneeId
FROM TblTasks,TblAssignments
WHERE TblTasks.TaskId=TblAssignments.AssignmentEntityId
AND TblAssignments.AssignmentEntity='Task'
AND TblTasks.TaskId=@TaskId)
or
(SELECT UserId FROM TblProjects WHERE ProjectId=@ProjectId)
)