cancel
Showing results for 
Search instead for 
Did you mean: 

Assign resource to task via abap automatically

Former Member
0 Kudos

Hi experts.

I need to assign via abap a resource to a task.

The scenario is the following:

I have a RoleA with 4 resources staffed (Resource1, Resource2, Resource3, Resource4) and 2 tasks assigned (Task1, Task2).

I need to assign for example Resource1 to Task1 via abap knowing:

- Task1 guid

- RoleA guid

- Resource1 business partner guid.

How is it possible?

Is there a function module or a method to do this?

Thanks,

Luca

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Solved on my own with function

RPLM_PSS_UPDATE_BL_EL

Former Member
0 Kudos

Hi Luca,

We have already asssigned task to role and now we have to assign resource to role uing BAPI "BAPI_BUS2177_STAFFING_ADD". But we are getting dump while using this bapi.

Could you please provide more details how you have done this?

Thanks & Regards,

Anil Salekar

former_member324993
Active Contributor
0 Kudos

HI,  Luca Giardino

   We used RPLM_PSS_UPDATE_BL_EL  but system have dump

mariano_sabiche
Active Participant
0 Kudos

Hi Luca;

Take a look to this MF:

You have the BAPI --> BAPI_BUS2175_ROLE_ASSIGN_ADD to assign a Role to a Task or BAPI_BUS2177_TASK_ASSIGN_ADD to assign from Project Role to a Task GUID.

The BAPI --> BAPI_BUS2177_CANDIDATE_ADD you can assign candidates to a Role.

To create staffing into the project, you have the BAPI --> BAPI_BUS2177_STAFFING_ADD.

I assign to all the task's the Roles and Resources with the Upload Excel File --> DPR_DX_PROJECT.

Hope this help you.

Best regards.

Mariano

Former Member
0 Kudos

Ok Mariano, thanks for your answer.

But I need the last assignment:

- With BAPI_BUS2177_STAFFING_ADD I can add a resource to a role (DONE);

- with BAPI_BUS2177_TASK_ASSIGN_ADD I can add a task to a role (DONE).

How is possible to do the last link Resource->Task?

mariano_sabiche
Active Participant
0 Kudos

Luca;

You can´t link a Resource directly to a task, because you need a Role.

That's cause you need to inform a Role to a task.

Best regards,

Mariano

Former Member
0 Kudos

Mariano, I know.

My scenario is:

A role with tasks and resources assigned...

I need to assign a resorce of the role with a task of the role knowing all guid of objects...

The operation that we have pushing the button 'Assign Resource' in TASKS tab of a role after the selection of a task from table Tasks Assigned to Selected Project Role (task assigned to the role previously) and a resource from table Resources (resource assigned to the role previously)...

mariano_sabiche
Active Participant
0 Kudos

Luca;

I'm thinking that we are talking about the same.

Are you talking about this screen --> http://www.imagehosting.com/photo/resource-tab-from-project?context=user ?

Best regards,

Mariano

Former Member
0 Kudos

Exactly...My scenario is exactly the same.

I need to do via abap in your screenshot:

- select row of task Eleboracion Definicion de la necessidad

- select row of resource N.N.1

- push the button 'Asignación de recursos'

After this the resource N.N.1 will be assigned to task Eleboracion Definicion de la necessidad...

I need to do this via abap...

mariano_sabiche
Active Participant
0 Kudos

Luca;

I never used this functionality.

This "Resource" tab strip that you mentioned used the Object BUS2177.

I found this BAPI's:

BAPI_BUS2177_CREATE

BAPI_BUS2177_CANDIDATE_ADD

BAPI_BUS2177_STAFFING_ADD (this BAPI may helpyou)

Explore with this, I think that you are closer to solve this thread.

Hope this help you.

Best regards,

Mariano.

PD: Points will be apreciated.

Former Member
0 Kudos

Mariano,

Object BUS2177 is the object for role.

I need to find BAPI for other object (that I don't know) that is useful to populate table DPR_ENTITY_LINK that is my trouble.

I need to find for this table the partecipant_guid (that is different from business partner guid).

Regards,

Luca

Former Member
0 Kudos

Hi again, experts...

Aren't other suggestions?

I'm not able to assign resource to task automatically...

Thanks,

Luca