cancel
Showing results for 
Search instead for 
Did you mean: 

Conditions behaves different SWUE/FM SWE_EVENT_CREATE_FOR_UPD_TASK

Former Member
0 Kudos

Hi

We have had a problem with the conditions via SWB_COND. So we had to change the conditions and remove a parameter. But after that removal the Workflow won't start. We get the error shown below in the message of event trace. But manually triggered event via SWUE workes fine and acts acording to the updated SWB_COND.

I use SWB_COND to set conditons for a WF to start. Parameter VAR must not contain 'X'.

Operator: VAR NE 'X'

When we use FM SWE_EVENT_CREATE_FOR_UPD_TASK (see below) trigger event

(containter totally empty : parameter VAR is not set to anything)

...the event is triggered BUT with:

Action: "Check FM ends with exception"

Message: Operator 'NE': The value of the left operand cannot be determined

CALL FUNCTION 'SWE_EVENT_CREATE_FOR_UPD_TASK'
       EXPORTING
            event           = gc_ev_pr_created
            objtype         = gc_obj_bkpf
            objkey          = lv_obj_key
       TABLES
            event_container = lt_container.


  COMMIT WORK.

When using SWUE to trigger the event with SAME object key and same parameters (parameter VAR is not filled) - Workflow is triggered OK

Question:

So I have a workflow that won't trigger when the Event is triggered via a FM caused by an unfamiliar Operator in the condition. (in Event Trace all is RED)

BUT the same WILL trigger if I call the SWUE and trigger the Event myself. In the Event Trace all is GREEN then...

Anyone have any ideas....

I've checked the OSS / the web / this forum ... but couldn't find anything that lookes the same... Please help

Is there a buffert or something that need to be updated in order for the FM SWE_EVENT_CREATE_FOR_UPD_TASK to be aware of the Conditions...

Best reg

Henrik

further info:

The event linkage contains:

Receiver FM = SWW_WI_CREATE_VIA_EVENT

Check FM = SWB_2_CHECK_FB_START_COND_EVAL

Accepted Solutions (1)

Accepted Solutions (1)

former_member186746
Active Contributor
0 Kudos

Hi,

try a different FM one of the SAP_WAPI* ones

Also put a break-point in the check function module.

You can put a activate HTTP debugging for WF-BATCH if you temporary change that user to dialog.

Kind regards, Rob Dielemans

Former Member
0 Kudos

G'day!

I changed to SAP_WAPI_CREATE_EVENT instead.

So far it looks OK!

The workflow is triggered OK in Event-trace... and the Condition was evaluated OK..

(I hope the same will be in Production!)

Thankyou VERY much for quick response!

Best reg

Henrik

former_member185167
Active Contributor
0 Kudos

SAP_WAPI* wins again!

Answers (1)

Answers (1)

former_member186746
Active Contributor
0 Kudos

Also do the following.

In SWE2 use your userid as receivertype and SWE_EVENT_MAIL as receivertype function module.

Now when an event gets triggerd you'll get a mail in your SAP inbox. Compare these 2 to see what the differences are.

Good luck!

Rob Dielemans