on 11-10-2009 7:59 PM
Hi,
I am using BSTAT(2nd Program Grouping) feature for giving default value to 2nd Program Grouping field as per the decision Tree:-
Decision Tree 1:
BSTAT
BAREA
US
PERSK
- 01
- AAAA
- Otherwise
- BBBB
Here the Structure(standard) is PME30(by default) but since it doesnot have field called STELL(Job) so i am using PME39 which contains the field STELL(job) to be used for decision making...but when i changed to PME39 and activated the feature...
Actually I need to use the following structure for the decision
Decision Tree 2:-
BSTAT
BAREA
US
STELL
- 00000011
- AAAA
- Otherwise
- BBBB
But before that when I tried to use the old Decision Tree 1 for PME39 structure for testing as it contains BAREA and PERSK fields, So logically it should work for PME39 also but its not working. I just have a question, can we use PME39 structure instead of PME30 ?
As when i am trying to create Infotype 0171 for any employee with PERSK = 01 then it should give AAAA(as per decision tree1) for 2nd Program Grouping .It is giving for PME30 structure but not for PME39...
Can any body let me know, what exactly i am missing..
I would really appreciate a quick reply.
-Manoj
Hi Manoj,
Look at the below piece of Code extracted from SE51 >> MP017100 >> Screen 2000 >> Module P0171 in the PBO.
A Function Module is called 'HR_BEN_GET_FROM_FEATURE_BSTAT'
If you check this Function Module in SE37 >> this calls yet another Function module 'sap_get_emp_bstat_from_feature'
which has the below code...
form sap_get_emp_bstat_from_feature
tables error_table structure rpbenerr
using value(pernr) like pskey-pernr
value(begda) like sy-datum
value(endda) like sy-datum
value(barea) like t5ub3-barea
pers_assignments type pccet_pernr
value(react) like sy-msgty
changing bstat like t5ub9-bstat
subrc like sy-subrc.
*
data: retcd like sy-subrc,
decision_structure like t549d-struc.
*
subrc = 0.
*
call function 'HR_BEN_GET_FEATURE_STRUCTURE'
exporting
feature = 'BSTAT'
reaction = react
importing
decision_structure = decision_structure
subrc = subrc
tables
error_table = error_table.
check subrc = 0.
check decision_structure = 'PME30'.
*
perform fill_pme30 tables error_table
using pernr
barea
begda
endda
'BSTAT'
pers_assignments
no_log
changing subrc.
Essence is the module pool program of Infotype 0171 checks the feature which has the structure PME30 and if you try to use PME39 with similar characterestics, it will still not pick up as the program is designed to pick up from PME30.
Hope this helps !!!
Good Luck !!!
Kumarpal Jain.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
One thing to note when changing the structure of a Feature: Every change made to the structure affects the programs that read the feature.
This could be the reason why your decision tree is not producing the expected result once you change the SAP standard feature structure from pme30 to pme39.
What I would normally do if a standard feature does not satisfy my requirement is to research if there is feature exits provided by SAP.
And for Benefits there are tons of feature exits provided by SAP. Using feature exits will allow you to make any decision you want more flexibly and therefore allowing you to have BSTAT to return any value as your requirement desires.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
96 | |
10 | |
9 | |
6 | |
3 | |
3 | |
3 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.