on 04-18-2016 10:50 PM
Hi Experts,
I am just wondering which rule/action will fulfill below requirement .
I want to stop processing of event message for one of expected event .
I do not want to stop processing in preprocessing function module as i need to create a error log and trigger alert .
QUIT EVENT MESSAGE PROCESSING rule works for unexpected event only .
1) How to fill NOT_RELEVANT field in table EH_EXPEV.
2) If I populated INVALID_DATA field in preprocessing , will it reach to ruleset to create error log and trigger email .
Thanks in Advance ,
Rajesh
1) How to fill NOT_RELEVANT field in table EH_EVMSG EH_EXPEV.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Rajesh,
Is there any reason why you want to populate non_relevant in EVMSG table? If you don't care then try activity STOP_PROCESSING and see if it works for you.
For preprocessing, if you add invalid_data flag = 'X', I am guessing it should still go through ruleset. Haven't tried it but breakpoint should help.
Thanks,
Vishnu
Hi Rajesh,
1. Create a new custom activity function in ruleset and try to call /SAPTRX/CL_EH_EVENT_MSG_MODEL -> UPDATE_EH_EVMSG to update "X" flag in
l_eh_evmsg-not_relevant | = i_irrelevant. |
2. Then trigger email.
Check and let me know whether this will work.
Let me check other ways also.
Regards
GGOPII
Hi Gopi , Hi Steefan ,
i would have surely gone for that option , however that will need a good developer who can understand the logic from ruleset and use the same logic in preprocessing properly .
Since i am not comfortable on that side so I think i should go for option where i will keep logic of triggering email and error message on ruleset . Only thing i will update EH_EVMSG table with IRRELEVANT indicator as Gopi proposed .
/SAPTRX/CL_EH_EVENT_MSG_MODEL -> UPDATE_EH_EVMSG to update "X" flag .
In this way , although event is reported in EM but since IRRELEVANT indicator is set so any reporting requirement can look into this .
More over I will create a rule set for not to update event in TM /ECC . So i think i should be good .
Do you guys see any other issue .
Regards,
Rajesh
Hi Rajesh,
I have manually updated "X" flag in NOT_RELEVANT in an existing event to check whether it is visible in EH_LIST.
The event message is not still visible in EH_LIST. So, if you think this is good then you can go ahead with this approach. I couldn't see any issue unless until if run any report and check this flag specifically to ignore or include.
Edited[Gopi]
Regards
GGOPII
Rajesh,
Looks like your preference is to write logic in ruleset to make it irrelevant but /SAPTRX/CL_EH_EVENT_MSG_MODEL->UPDATE_EH_EVMSG is a protected method.You cannot just call it outside of the model class. Make sure it works before you spend lot of time designing and documenting it.
Thanks,
Vishnu
Hi,
never tried this for Expected Events but i doubt it will work.
Even if the EH_EVMSG gets the irrelevant flag i think the EE will be reported then.
Own methods you could add as Enhancement with:
(1) start Class Builder (SE24) for class /SAPTRX/CL_EH_EVENT_MSG_MODEL
in display mode
(2) The "Methods" tab appears
(3) Select menu function "Class >Enhance"
(4) The "Create Enhancement Implementation" popup appears;
create an enhancement implementation here
(5) after creating it you come back to the "Methods" tab, but now you
are in mode "Enhance class "
(6) scroll down to the end of the methods list; here you can add a
new method now ...
That new method will be automatically connected to
your enhancement impelmentation (you can see that in column
"Enhancement implementation")
Then you could also call protected methods.
Best regards,
Steffen
Hi Gopi ,
How did you set EH_EVMSG as not relevant manually . Did you enter value while executing BAPI ADD EVENT MESSAGE 02 ?
I want to set this and want to see if solution will work .
I want to see that if event message is reported and EH_EVMSG is set as Not relevant , will event be shown as reported event in execution button of freight order .
Regards,
Rajesh
Hi Vishnu , Hi Steffan , Hi Gopi ,
Thanks for your valuable suggestion .
We are planning following method to call protected method of /SAPTRX/CL_EH_EVENT_MSG_MODEL class .
1) Create a sub class of SAPTRX/CL_EH_EVENT_MSG_MODEL and create a public method .
2) We will call UPDATE_EH_EVMSG from method of above subclass .
Please check following SCN link and let me know your view .
https://scn.sap.com/thread/278775
Regards,
Rajesh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
9 | |
4 | |
3 | |
2 | |
2 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.