cancel
Showing results for 
Search instead for 
Did you mean: 

Custom processing for every Workflow event

Former Member
0 Kudos
78

Hi,

As soon as any workflow event is raised, I want to read

data from my custom Z tables and do custom processing for that event.

Thanks,

Sudheer

Accepted Solutions (0)

Answers (1)

Answers (1)

pokrakam
Active Contributor
0 Kudos

Hi Sudheer,

Reacting to every event is generally not recommended. There can be millions of events published thoughout the day!

Could you tell us what you are trying to accomplish, perhaps we can help find an alternative way of getting your result.

Cheers

Mike

Former Member
0 Kudos

Hi Mike,

What we want to do is for any event raised in the system that is related to worklow (Like PO Approval is required or Credit approval is required), we want to check if that event is in our custom table. If so, then

we want to do special processing like logging some data in the custom tables and also notifiying certain users about it (these users will be different from users who recieves workflow).

Thanks,

Sudheer

pokrakam
Active Contributor
0 Kudos

Hi Sudheer,

You say <i>check if that event is in our custom table</i>. No need to reinvent the wheel, the event linkage fulfils exactly this function. If you want to perform an action for an event then add the event into the event linkage (tx. SWETYPV) instead of - or as well as - your custom table. It doesn't matter if you have the same action in there for 1, 50 or 100 events.

You can have more than one linkage per event and you can start more than just workflow. The receiver function module is what 'receives' the event. It's just that: a FM to be executed when an event happens. This is the event manager's job, which is what you're trying to duplicate as I understand it. The receiver can either be a workflow or anything you choose - just follow the standard FM interface required here (have a look at any other linkage's FM for the parameters).

All that aside, it sounds like somethng I'd do in a workflow. Either as two extra steps in the beginning of my workflow or as a second workflow. (Background step to log data and a sendmail step to notify users).

Cheers

Mike