Wednesday, July 9, 2014

ABAP - Solving the problem of field splitting its contents into two columns in Excel

Have you coded a report program that is supposed to populate a field into 1 specific column of an *.CSV or Excel file output but found that the field has split itself into two different columns?


To make matters worst, all the fields or columns in the Excel file appear to shift to the right from this incorrect column onwards.


For my case, the problem lies in the data where there exist a comma.


For example "Project Manager, Water Industry"


Thus the "Project Manager" stays in the expected column but the "Water Industry" appears in the next column.


To solve this problem, I use the REPLACE keyword and replace the comma with SPACE.


REPLACE ALL OCCURRENCES OF ',' IN ev_pay_area with SPACE.

Sunday, July 6, 2014

Using TARIF to default IT0008 from IT1005 Planned Compensation

Using the Feature TARIF with return value:-
  1. S (for paygrade check), T710
  2. T (for payscale check), T510
  3. D (for direct check).
  4. 1 (for Payscale)
  5. 2 (for paygrade)
  6. 3 (for Payscale)


These are the tabs in IT1005-planned compensation.

An example configuration would be '  /  /S'





Related information regarding the amounts that are defaulted 
The key is the entry in tables T710 and T710A for the pay grade.  The minimum and maximum amounts are set in T710 and default into IT1005 when you enter the Country, Pay Scale Type, Pay Scale Area, Pay Grade and Level on the first tab (Pay Grade).  In T710A, you set the Message Type and Reduction Rule for the Error, Warning or No message if outside the minimum and maximum for the pay grade and level. 

So your settings in T710A control the warnings.  IT1005 only defaults the Pay Scale Type, Pay Scale Area, Pay Grade and Level.  The minimum and maximum salary amount comes from T710. 

If Feature TARIF is returned with P, then this takes the defaulting from T510.