Thanx for reading this...
Here's part of the code...
p_Month = MONTH(EOW)
use EM excl
do case
case p_Month = 1
scan for hire_date < {02/01/97}
** 1st, set grant and ent.
replace grant with 80.0, entitlement with 80.0
** Next, re-calc for pos. balance.
replace carryover with balance, ;
balance with grant ;
for balance >= 0.0
** Now, re-calc for neg. balance.
replace balance with (grant + balance), ;
carryover with 0.0 ;
for balance < 0.0
endscan
case p_Month = 2
...SNIP...
endcase
The other 11 months are similar to case p_Month = 1.
I thought scan...endscan was supposed to loop thru EVERY record that
matches the for condition AND execute all the statements within. In
this case however, the trace window shows that the scan EXITS after it
processes the first record. The other records that meet this criteria
do not get processed and replaced as per the code.
Please tell me why this is happening, and how to fix it. I need the
replacements to run against ALL records that match the scans' "for
condition".
Thanx much for your help. RH