cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Badi agent determintaion is failing with the error, no agent determined

0 Kudos
3,647

As part of S/4 Hana green field implementaion project we are migrating from ECC to S/4 Hana.

As part of data migration we need to implement the workflow in S/4 hana system for PR( Purchase Requisition – ME51N) creation. Whereas, we successfully configured and triggered Workflow in Role based and the approval levels or Manager of Workflow Initiator and Manger of Workflow initiator’s Manager.

But now, we need to add one more level of approval which will be level 1 approval and the approver would be same person who will create the workflow ( Initiator will become level 1 approver). For the same we have identified the BADI(MMPUR_WORKFLOW_AGENTS_V2) to add the approver and implemented the logic.

Issue:

When we create the PR from ME51N transaction, workflow is being triggered and it is ending up with the error as below.

No agent determined ( rule ID: Badiagentdetermination)

Accepted Solutions (0)

Answers (3)

Answers (3)

0 Kudos

Badi was not activated correctly. have corrected and activated the BADi and WF is successfull

0 Kudos

Thank you for the reply Sijin. As am new to workflow, I followed one document in implementing the BADI. Can you please help me debugging( I tried to find in google, but no luck) the BADI logic from workflow triggering or from the workflow re trigger.

Sijin_Chandran
Active Contributor
0 Kudos

First can you confirm on the Flexi Workflow Stuff ?

There is a place in SPRO where Functional set it up with "Active" status.

Once you are sure that Flexi Workflow is active then this is the right BADI for agent deterimination.

If instead of Flexi its normal Workflow being used there there are 2 SMODs for this, one for PR and other for PO.

For debugging try by setting External Break-point with the user of SAP Workflow.

or else check the failed rule using PFAC Tcode.

Thanks,

Sijin

Sandra_Rossi
Active Contributor
0 Kudos

Please use the COMMENT button for comments, questions, adding details, replying to OP comment, etc., ANSWER is only to propose a solution, dixit SAP text at the right of the answer area.

Sijin_Chandran
Active Contributor
0 Kudos

Hi Manoj,

First make sure on that it is Flexi Workflow which is being used rather than traditional Workflow for this scenario ,with your Functional Team.

MMPUR_WORKFLOW_AGENTS_V2 is for Flexi Workflow scenario.

If the above is confirmed then check in the BADI why "approverlist" is not getting filled. And also one more thing, in case for the scenarios/conditions no agent(s) gets determined then you should have a RETURN statement there.

Thanks,

Sijin

0 Kudos

Hi Sijin,

I have a requirement to determine agent determination for flexi workflow only..I tried to create a PR from GUI and kept BP with SAP workflow user id but it was not triggered and got the result as error...I have not created a implementation for this BADI yet but checking with standard existing implementation where this BADI is triggering or not?
Am I checking it in wrong way?? only after creating a custom implementation only this BADI will get trigger is it like that?
please let me know your comment on the same.
regards,

Rajeshwari