Skip to Content
0

How to pass the value from VARGB operation?

Apr 15 at 04:00 PM

54

avatar image
Former Member

I am using below operations to successfully get the days from the Hiring date. I want to compare the joining date with 15th of that month;

TABLEP0000

VALEN 2

VAOFF 6

VARGBBEGDA

01

02

**

the problem is, the days could be from 01 to 31, I don't want to list 31 combinations, how can I pass the VARGBBEGDA key value to NUM or AMT? or how can make a comparison > 15 or <15?

Pls share your comments, thanks

Gordon

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

3 Answers

Yishun Li
Apr 16 at 02:01 AM
0

NUM=BBEGDA, AMT=BBEGDA.

You can check the document of operation VARGB and TABLE.

The docuemnt of B used in NUM or AMT is like below.

B Tables
With the TABLE operation, when the system processes a
personnel calculation rule it calls a particular table.
With operand B for operations NUM, RTE, and AMT,
the system finds the line of this table that is
relevant to the employee for whom payroll is currently
being performed. The value of this field, which is
entered at locations nnnnn, is written to the current
NUM, RTE, or AMT field. For the field names, see
the Data Dictionary

Show 1 Share
10 |10000 characters needed characters left characters exceeded
Former Member

Thanks for your reply. however it does not solve my issue. BEGDA is a date type, however both NUM and AMOUNT and number and amount type.(XXX.00). when using the operation NUM=BBEGDA, AMT=BBEGDA. is used, it automatically convert the date type into an integer, so I can not using these two operation to get the days from the date.

by the way, I am using "TABLEP0000" to read the entry date, if there are multiple records in P0000, how do I loop with this table, pls advise, thanks


0
avatar image
Former Member Apr 18 at 03:41 PM
0

Hi YiShun,

The TABLE operation doesn't always work, if there are multiple records in a internal table, or table has a header line, TABLE operation can't bypass the header line, therefore returned incorrect value.

after DATES function, all the date type stores in an internal table DATUMDRUM,,, is there an operation can read table content from this internal table?

Anyone who had worked on this, pls share your comment, thanks

Gordon

Share
10 |10000 characters needed characters left characters exceeded
BELBARAKA Naima May 03 at 02:58 PM
0

Hi YiShun,

if you want to compare the number of days to 15 I propose the following cycle (see capture), for me the date system is written as YYYYMMDD example 20180503 for May 03, 2018


vargb.png (9.1 kB)
Show 1 Share
10 |10000 characters needed characters left characters exceeded

hope this answer helps Duma

0