Skip to main content
The World's Best Known Brand for Microsoft Project and Project Server Expertise

Project Server Experts Community Site

Go Search
Project Server Experts Community Site
  
Project Server Experts Community Site > Project Server FAQ KnowledgeBase > deletecancelledtasks  

Web Part Page Title Bar image
How do I delete cancelled tasks from each user’s timesheet?

You May Have Been Automatically Redirected to This Page, Which Has a New Address (URL). Please Update Your Bookmarks / Favorites Accordingly.

Background Information

When a project manager cancels a task by removing the resources assigned to the task, and publishes the changes to Project Server, each resource’s timesheet page displays a large X indicator to the left of the task name in Project Web Access. Note: Cancelled tasks also appear on the View resource assignments page in Project Web Access as well.

Resolution

Users can delete cancelled tasks from their timesheets in Project Web Access by selecting a task and clicking the Hide button on the toolbar above the timesheet grid. This approach hides the cancelled task but does not remove it from the Project Server database.

To completely remove cancelled tasks from the Project Server database, the Project Server administrator can run the following SQL Server script:

delete from MSP_WEB_ASSIGNMENTS
where WASSN_ID IN (
select ma.WASSN_ID from MSP_WEB_ASSIGNMENTS ma
join MSP_WEB_PROJECTS mp
 ON ma.WPROJ_ID = mp.WPROJ_ID
join MSP_WEB_RESOURCES mr
 ON ma.WRES_ID = mr.WRES_ID
where
ma.WASSN_DELETED_IN_PROJ <>0
--AND mp.PROJ_NAME like '25713%'  --uncomment it for specific project
)

If the Project Server administrator wants to view a list of cancelled tasks before deleting them, he/she can run the following SQL Server query:

select ma.WASSN_ID, mp.PROJ_NAME, ma.TASK_NAME,mr.RES_NAME, from MSP_WEB_ASSIGNMENTS ma
join MSP_WEB_PROJECTS mp
 ON ma.WPROJ_ID = mp.WPROJ_ID
join MSP_WEB_RESOURCES mr
 ON ma.WRES_ID = mr.WRES_ID
where
ma.WASSN_DELETED_IN_PROJ <>0
order by 1