I’ve found another tail story of SAP bugs by accident a few days ago. Lucky me, although it’s quite paint full to trouble shoot the mistakes. It was relating to the processes in defining HR Enterprise Structure, but lead to the incorrect currency in term of payroll results. In my SAP environment, we’ve been defining some numbers of country grouping in one box, that is used by different company code, personnel area and sub areas in their enterprise structure. On top of any HR configuration, it is country group configuration at SAP global setting that becomes as the initial Default Payroll Currency definition.
Furtherly, there’re several ways to be chosen in defining Default Payroll currency at HR module, as explained as follows:
1. The definition of SAP Enterprise Structure.
- IMG : Global Setting : Country Definition (in here we can define what the default currency for the country ID)
- Enterprise Structure -> Definition -> Finance -> edit,copy,delete company code (in here we can define what the default currency for the company code)
- Enterprise Structure -> Definition -> HR -> Create personnel area and sub area (that is need to be linked with its company code)
- Enterprise Structure -> Assignment -> HR -> Assignment personnel area to company code (that is also need to be linked with its personnel area)
2. Through, Personnel Management module in HR IMG path. By defining pay scale type/area, employee sub group grouping and CAP (Collective Agreement and Provision)
SAP has the capability in using multiple payroll currency, but from what I understand so far, it is only possible to define that case only by using step 2, other than defining through the enterprise structure configuration that will may lead us to the inconsistencies configuration. Below illustration will explain the inconsistencies in more detail.
The Issue background:
We’re using currency IDR (Indonesian Rupiah) as default currency for country grouping Indonesia (34), but somehow all payroll result was converted to currency SGD (Singapore Dollar), although we do not define it in our payroll configuration (Step 2:By pay scale are/type and etc). Since it was affected payroll result globally, then, suspected, the issues should come from the enterprise structure definition.
Pls take a look at the personnel area configuration screen (T001P) beside, notice that personnel area 1170 is linked to the company code 1201 “AND” configured with country grouping 34 (Indonesia)
That is actually the issue was coming from. Personnel area 1170 and its company code 1201 are supposed to be defined by country group 25 (Singapore), by it was forced as country group 34 (Indonesia), by mistake. While, in its detail configuration, company code 1201 is configured using SGD as its default currency. From here, I haven’t aware yet since I assumed that SAP has a kind of level priorities in defining its payroll currency through the enterprise structures configuration.
To come into this screen, we have to choose the country group ID at initial step. Therefore, it is clear enough that the screen will list all personnel areas and other information only under the same country grouping. Lucky me, the issues was caused by personnel area 1170 that was becoming as “the first personnel area record” by ascending order in the T001P view.
The root cause
It is clear that, currency IDR (Indonesian Rupiah) is set as default currency for country grouping 34 (Indonesia). But why all of my payroll result currency are being converted to SGD, is because of incomplete of the Abap program logic in payroll driver. Found that the existing logic is :
select single * from t001p where Molga = Employee Molga
Notice that the SQL criteria is using only MOLGA, whereas country grouping. So when, there are some inconsistent configuration, such I did, SAP will always assume that all personnel area under the same country group should always use the same currency. And by using “select single” clause, SAP will only and always retrieve the first record. In my case, as the first record is personnel area 1170 linked to company code 1201 that is using SGD as its default currency. That’s explaining why my payroll results for all personnel areas under country grouping 34, are being converted to currency SGD.
The Conclusion/Solution Propose:
- With the existing SAP logic, we CAN NOT define multiple payroll currencies through the enterprise structure configuration.
- Although, it does not intend to propose to SAP developer to allow it as solution no.1 above, but it DOES recommend for SAP side to put any additional SQL criteria to avoid such as my case in future. The logic will may look like this:
select single * from t001p where molga = employee molga AND bukkrs = employee bukrs
Note: it is not the correct Abap code, just simplifying the code, however the idea is to put bukrs (company code) as the selection criteria in the abap logic.
Otherwise, SAP should put the case as their lack or implementation limitation in their documentation as a part of the responsibility to their customer.
Any shared comments and/or experiences related to the issue, would be really appreciate.