cancel
Showing results for 
Search instead for 
Did you mean: 

Raising event Hired on BUS1065

Former Member
0 Kudos

I want to start a WF when event hired on BUS1065 is raised. Problem is that i can't find out how to get the event raised. I have checked that SWEHR2 looks ok - Insert of PA0001 runs FM HR_EVENT_RULES_PA0001, and i would expect that to be enough.

SWELS is active with no restrictions, but the SWELS doesn't show that an event has been raised.

What am i missing - perhaps some HR specific customizing that I don't know about.

Any help would be greatly appreciated

Best regards

Poul Steen Hansen

Accepted Solutions (0)

Answers (4)

Answers (4)

Former Member
0 Kudos

This is what I have right now:

SWEHR2:

P 0001 INS BUS1065 HR_EVENT_RULES_PA0001

P 0001 INS 100 BUS1065 CACS_LOG_HRINFTY

SWELS: On - no restrictions.

SWETYPV:

BOR Object Type BUS1065 HIRED WS97800524 Type linkage is marked.

FM HR_EVENT_RULES_PA0001 does only look for activity (INS/MOD etc.) and if before_image is initial (i.e. hiring). It doesn't seem to depend on a specific personnel action.

Hiring activity started in PA40. WF is not started (and no event is raised (SWEL)) when saving IT 0001.

I appreciate the answers so far, but i still need the right tip to help me solve this problem!

Best Regards

Poul Steen Hansen

former_member184112
Active Contributor
0 Kudos

Hi Poul,

You will probably need to test whether a workflow will be triggered by the event without always having to go through the business process of creating a new object instance every time. (However, you will have to know this, so don’t think you are getting off scot-free). For these purposes, you can use the test tool SWUE to create the event.

After you fill in the object key, and click on the ‘Trigger Receiver FM Synchr’ flag, then push the ‘Create Event’ button

Thanks and Regards,

Prabhakar Dahrmala

KKilhavn
Active Contributor
0 Kudos

> FM HR_EVENT_RULES_PA0001 does only look for activity (INS/MOD etc.) and if before_image is initial (i.e. hiring). It doesn't seem to depend on a specific personnel action.

>

And exactly what does your version of HR_EVENT_RULES_PA0001 do if before_image is initial? If the statement is CHECK NOT before_image IS INITIAL that is your problem right there and you need to apply an OSS Note (or modify the program).

In the version of the function module I am looking at right now there is an IF-check, and if the before_image is initial, the variable event is set to "HIRED" - nothing else is done in that branch.

former_member186746
Active Contributor
0 Kudos

Hi,

also check if entries exist in SWEHR3, because if there are, these are used instead.

regards, Rob.

Former Member
0 Kudos

Hi Paul

Make sure the FM HR_EVENT_RULES_PA0001 caters for your hiring action, this may not be the case always.

You may have to copy this to a Z one to make any changes.

BTW hiring is done via PA40.

Let us know how you go.

Regards

Ravi

former_member184112
Active Contributor
0 Kudos

Hi,

HR Infotype (can be restricted to a subtype) must be linked to business object type.

Operation on the Infotype must be linked to an event.

A function module FM HR_EVENT_RULES_PA0001 will determine the event (of the specified business object type) dynamically based on old and new values of the Infotype.

Remember: SAP provides number of predefined links between Infotype operations and events. These links can also be replaced.

Check the Event Linkage

If import elements are defined in the WF Container with the same ABAP Data Dictionary Type or Object Type Reference as that of event container, Builder will try to match the elements and propose the binding.

Receiver Function Module at SWETYPV is defined by the system when the linkage is created.

Thanks and Regards,

Prabhakar Dharmala

former_member186746
Active Contributor
0 Kudos

Hi,

It depends on how you update this infotype, normally through pa30 the event should get raised, so check that first.

Also if you use the event queue (SWEQADM) delivery of event could be delayed.

Kind regards, Rob Dielemans