!!BW - Beginning of Week 

Beginning of Week (BW) will return the 1st day of the week (Sunday) of the date found in Operand 2. 

Statement: If an employee is terminated in the 1st week of the pay period, divide the Life Plan deduction collected in half (the deduction is stored in PC 1700).

||Line||CMD||OT||Operand 1||OPER||OT||Operand2||OT||Operand3||If Goto||	Else GoTo
|00010|IF|DB|DES.STATUS_CODE|EQ|A|TERMINATED|  |  |00100|99999
|00100|LET|V|WEEK 1 END DATE|BW|$S|PERIOD-END-DATE|  |  |00110|	
|00110|IF|DB|EEM.TERMINATION_DATE|GE|$S	|PERIOD_START_DATE|  |  |00200|	99999
|00200|IF|DB|EEM.TERMNIATION_DATE|LE|V|WEEK 1 END DATE|  |  |00300|	99999
|00300|IF|PC|1700|GT|N|0|  |  |00400|	99999
|00400|LET|PC|1700|DIV|PC|1700|N|2|99999|	
|99999|EXIT|  |  |  |  |  |  |  |99999|	

As with BD, the result of BW may also be changed by a value in Operand 3. 

Refer to BD in Section 6.5.2. for possible Operand 3 values.