on 01-07-2015 11:15 PM
I am really new to payroll schema and trying to achieve a small functionality
I have a wage type that have amount calculated from rate and number. After the amount is calculated, I want to remove the number so that RT will have only amount and rate and not the number.
This was the earlier PCR content
MULTI NRA
ADDNAE*
I tried changing it to as below to zero the number but its removing the amount along with the number
MULTI NRA
ZERO = N
ADDWTE
Please help with this
First, please mention what Function you are using to call your PCR since you are writing directly into the Results Table (using ADDNAE or ADDWTE).
You have not mentioned what data is being processed, but I would suggest that you try
MULTI NRA
ZERO= N
ADDWTE*
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Yes, I understand that you want the output to be in RT, but from where is the information comming from? What function is used to process the PCR?
If the WT you want to modify is already in RT, then you won't be able to delete it's Number and the PCR should be built to process the Input Table just before the WT is cumulated and transfered to RT.
Wage types are not in RT until this rule is called. This rule is the one that generates the wage type.
PRT is the function used to call the PCR. for each wage type 86XX, 85ZZ wage type should be generated with a specific amount but these 85XX should not have the number in RT but only the amount. Hope this information helps.
/002 is in the RT when the rule is called and hence rate is picked from here and hours are picked from the wage type 86XX and amount is calculated to put in 85XX wage type.
Requirement is to only have amount in 85XX in RT and remove the number once calculation is done
Since the PCR is called by Function PRT, it is processing the WTs that are already in RT.
According to what you just wrote, the RT must contain WTs /002 and 86XX, and you want to use the Rate from WT /002, multiply it by the number of WT 86XX to get an Amount, and generate WTs 85XX containing only the Rate and Amount. Correct?
Here is an example I created using WTs that I have available at the end of schema ZAL0
This is a screen capture from the log detailing the processing
There are other ways to create the PCR, and it could have included all WTs in the 1XXX range. Basically, when processing the 1XXX WT, the Rate is set anew, the multiplication is done and the Number is deleted, and the result is saved under a different WT.
As for the Rate, the WT I used had a split so I used a temporary variable that would save only the value of the last split as I could not garantee that the WT used would have the same splits as the WT being processed (and that can have an impact).
Hope this helps.
If your query is answered you can close thread as well.
Regards
Venkatesh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
PCR syntax is wrong just write like below
MULTI NRA
ZERO= N (No space after ZERO= N)
ADDWTE*
Regards
Venkatesh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
7 | |
6 | |
4 | |
3 | |
3 | |
3 | |
3 | |
3 | |
2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.