cancel
Showing results for 
Search instead for 
Did you mean: 

SAP MDG Workflow - Skip a Step Scenario

Former Member
0 Kudos

Hey Experts,

How can we skip a Step in Rule Based workflow configuration based on an Entity attribute value?

General Scenario is that there are two Approvers in a workflow.

REQ > APR1> APR2> PROCESS ENDs (Requester is not a technical part of workflow, Therefore, Workflow has two steps)

Now in a special case (if an attribute has a particular value), the task should directly go to APR2 (skipping APR1). I have implemented dynamic user agent determination using BADIs which i will use to determine APR1 User Agent, but having a Step skipped is something new to me.

Two possible workflow executions could be -

REQ>APR1>APR2>END

REQ>APR2>END

Can you please share your knowledge on this point?

Regards

Pranav

Accepted Solutions (1)

Accepted Solutions (1)

former_member209780
Active Participant
0 Kudos

Hi Pranav,

Extend your single value decision table with a column which is your special condition. Then you can skip a step. For example if you want to skip a step for a material with standard price less than 100, you can extend your decision table with a new column 'price' and create two new rows one with condition <100 and other with >100. Hope this helps

Thanks and Regards

Goutham Kanithi

Former Member
0 Kudos

Hello

Thanks.

I kind of extended Single Value decision BRF+ Table and made it work.

This document was helpful.

http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/60f0cc68-5884-2e10-b8a9-a71ba25ad...

Regards Pranav

Former Member
0 Kudos

HI Guys, I managed to get the work done using BRF+  table extension that uses 'USMD_SSW_RULE_CONTEXT_PREPARE' BADI Definition extension. It is working for a single columns extension. what If i want to read values of two or more entity attributes and user them in BRF+ table. Is there a way forward using same approach (as in below link)?

http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/60f0cc68-5884-2e10-b8a9-a71ba25ad...

Answers (4)

Answers (4)

0 Kudos

Hi All,

I have a similar requirement ,

1)User will create a material .

2)when creating if he selects one plant then it should go to one user,

3)if he extends 2 plants then it should go to 2 users .

Can anyone provide me the solution and the best approach to do this , any document or step by step guide would be useful.

Thanks

sanjaydutta2
Discoverer
0 Kudos

Hi Sharath ,

did you get any answer

Former Member
0 Kudos

its very simple, in the Badi for workflows, you have to access the attribute and based on the attribute value return a custom action code. And you have to handle that value in the workflow configuration (brfplus) and just got to the step where you want to go if the attribute value is not met. let me know if you need more info. but this should be fairly simple.

Former Member
0 Kudos

1. if you are using dynamic agent select badi,

when you are preparing the table for agents, instead of agents use a non user agent step (which will be a system method). in the sys meth caller then create a handle for this step type and just pass any action you want. this can be re used anywhere in the process except parallel steps.  (create a dummy step)

2. if you are not using dynamic agent select but using the rule based workflow, then you can step 1, populate the generic context in the workflow from the UI or a system method and in the ruleset of the rules based workflow create a rule to modify your result.

3. very specific to the step, if you have a simple condition based on data, you can also add a column in the decision table as a condition and calculate result accordingly.

4. you can create a static method, or a fm which uses the request number as the key to read request data and return you the result in a way that will force the workflow to go to step n+! rather than n. you can call this from the rules based workflow using the expressing type function caller.

there are many ways to do it.. but best approach is number 1. since you develop once and can reuse this is not just one but many requests .

Former Member
0 Kudos

Hi,

You should look at this guide

http://scn.sap.com/docs/DOC-14879

Former Member
0 Kudos

Hey Tommy,

This documents is about dynamically determining the user/role for a Step. that BADI can not assign a step in its execution. right?

What I am trying to do is to get entire Step Skipped and task should go to Step 2 (skipping Step 1).

Regards

Pranav