Showing results for 
Search instead for 
Did you mean: 

Opeartion ADDDB - how does it work?

Former Member
0 Kudos

We have a bit of a weird problem with an employee - in essence he is getting the wrong overtime.

On investigation it seems that the our Time Type Z060 has a value in it, when it shouldn't.

There is a statement "ACTIO Z533" in our Time Schema which appears to zeroise the Time Type Z060 - the code is:

Rule GrRule TType VaKey Operation

Z533 * **** HRS=S Set

Z533 * **** ADDDBZ062Z Set day balance = 0

Z533 * **** HRS=S Set

Z533 * **** HRS-DZ015 Subtraction

Z533 * **** ADDDBZ060Z Set day balance = 0

Z533 * **** ADDDBZ061Z Set day balance = 0

The second line from the bottom is, I think, the line that zeroises the Time Type Z060. However, immediately after this code in the schema is a print of the values in the Time Types:

TimeType Name Number

Z070 Claimed Overtime 8.7000

Z062 WS Hours 7.0000

Z060 Hours Worked PT Overtime 7.0000

Z061 Hours Worked FT Absence 7.0000

Which shows that Time Type Z060 has a value of 7 hours!

How can this be? If it was zeroised immediately prior to the print. Has any-one come across a similar problem?

Any hints/tips gratefully received.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Rob,

are you sure, that Z060 is cleared with the shown statement? In the print of the TES, which you show in the lower part, there is no value shown for the time type Z015. To me it then appears, that by the statement:

Z533 * **** HRS=S Set

Z533 * **** HRS-DZ015 Subtraction

Z533 * **** ADDDBZ060Z Set day balance = 0

you actually put the number of planned hours from the daily schedule (HRS=S) into Z060, but since Z015 is probably empty, nothin is substracted => Z060 is not zero. Or am I wrong?

Former Member
0 Kudos


You may well be correct. (I am not familar with the Time Operations).

The help for the Operation ADDDB says:

Z Initialization (zero)

A value that already exists in the time type will

be overwritten.

Reversal of +/- sign

Prior to cumulation, the +/- sign of the hours-

number-field is reversed, in other words, the value

of the hours-number-field is multiplied by -1.

Which I read as it initialises the Time Type to Zero (as it says on the first line) - but is it saying (further down) that it reverses the hours and then adds the hours in?????????????? I am confused.

Are you familiar with the opeartion ADDDB? Do you know how the "Z" at the end means?

All help gratefully received



Former Member
0 Kudos


ADDDBZ060Z --> doesn't make the value of Z060 to zero, it just initializes the current value stored in that type in the daily balances table i.e. TES.

hope this helps....,


Former Member
0 Kudos


ADDDBZ overwrites the value in the time type.

for ex: if time type 'abcd' has a value 100, and you want to over write it with 150, then you need to write,

hrs = 150,


now the system first zero out the value in the time type and then add the value in the hrs field.


Former Member
0 Kudos

Hello Rob,

as the other colleagues wrote, the Z at the end of the operation states, that instead of adding the value of the HRS field to the current ammount in the time type (which would be case without the Z), it sets the value according to the current value of the HRS field, which in your case is probably the planned hours. It would be zero if there were some value in the Z015, but Z015 is probably zero at this time.

If you want to really clear the field, just say:



Answers (0)