PDS ProjectTaskCreate Inserting Task with proper Hierarchy

F

Fletch

Hi all,

I am currently inserting a task with a WBS code into Project Server 2003 via
the PDS ProjectTaskCreate Method. After calling the ProjectViewTablesCreate
Method to update the project in PWA view of the project, I am noticing that
the task is not added in the proper order.

Steps I am taking:

-Querying the source system to get the task data.
-Querying project server to select the proper project
-Querying project server to accertain the WBS code of the predecessor task
and the outline level of the task to insert.
-Generating the PDS Request XML
-Calling the PDS CheckOut Method
-Calling the PDS ProjectTaskCreate Method
-Calling the PDS CheckIn Method
-Calling the ProjectViewTablesCreate Method

After performing these steps I am able to see the task in PWA, but it is
appended to the bottom of the project instead of being in the proper
possition based on the WBS code.

*note* I also have attempted to solve this issue by setting the
TASK_OUTLINE_NUM via a SQL statement. The result was the same.

Example of my PDS ProjectTaskCreate XML:

<Request>
<ProjectTasksCreate>
<ProjectID>10</ProjectID>
<Tasks>
<Task>
<Name>MyTaskName</Name>
<ID>132</ID>
<WBS>3.23</WBS>
<OutlineLevel>2</OutlineLevel>
<Duration>480</Duration>
<Work>540</Work>
<ActualDuration>450</ActualDuration>
<ActualWork>510</ActualWork>
</Task>
</Tasks>
</ProjectTasksCreate>
</Request>

Any help of direction regarding this issue would be greatly appreciated.

Thank you,
Fletch
 
F

Fletch

Please Disregard my previous post. I have accomplished the task.

Work Around Steps:

- Query ProjectUniqueID and TaskUniqueID of known predecessor from
MSP_VIEW_PROJ_TASKS_STD Table (or custom view based on
MSP_VIEW_PROJ_TASKS_STD and MSP_VIEW_PROJ_TASKS_ENT pending on your usage of
Custom Enterprise Fields)
- Query TASK_ID from MSP_TASKS using the ProjectUniqueID and ProjectUniqueID
as the criteria
- Renumber TASK_ID field for all successors in the MSP_TASKS table to be
Current TASK_ID + 1
- PDS: CheckOut project
- PDS: Insert new task via CreateProjectTask Method
- PDS: CheckIn project
- PDS: ProjectViewTablesCreate Method

This should allow you to insert the task at the proper position in the
Project. I plan on writing a PDSExtender to perform all these tasks.

Good luck to anyone working on this type of implementation.

-fletch
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top