00001  IDENTIFICATION DIVISION.                                         11/03/08
00002  PROGRAM-ID.             DTSBU521.                                DTSBU521
00003  AUTHOR.                 TRICOASTAL CONSULTING LTD.                  LV011
00004  DATE-WRITTEN.           JANUARY 1991.                            DTSBU521
00005  DATE-COMPILED.                                                   DTSBU521
00006      SKIP3                                                        DTSBU521
00007 *****                                                             DTSBU521
00008 *                                                                 DTSBU521
00009 *    FUNCTION:  APPLY/REVERSE A PAYMENT DISTRIBUTION.             DTSBU521
00010 *                                                                 DTSBU521
00011 *                                                                 DTSBU521
00012 *    MODIFICATION LOG:                                            DTSBU521
00013 *                                                                 DTSBU521
00014 *    01/26/92  INITIAL DEVELOPMENT.                               DTSBU521
00015 *              WORK ORDER:                      PROGRAMMER: TCL   DTSBU521
00016 *                                                                 DTSBU521
00017 *    12/10/1998  REVIEWED AND MODIFIED FOR DC.                    DTSBU521
00018 *                REFERENCE: DC DEVELOPMENT      PROGRAMMER: EHH   DTSBU521
00019 *                                                                 DTSBU521
00020 *    02/20/2006  INTEREST CALCULATION MODIFIED - ONLY UI TAX      DTSBU521
00021 *                BALANCE INCLUDED.  P2200, P3000.                 DTSBU521
00022 *                REFERENCE: ADMIN ASSESSMENT    PROGRAMMER: GD    DTSBU521
00023 *                                                                 DTSBU521
00024 *    02/12/2008  INTEREST CALCULATION MODIFIED TO INCLUDE SUR     DTSBU521
00025 *                TAX.  P2200, P3000.                              DTSBU521
00026 *                REFERENCE: ADMIN ASSESSMENT    PROGRAMMER: ZL1   DTSBU521
00027 *                                                                 DTSBU521
00028 *    10/31/2008  INTEREST CALCULATION MODIFIED TO EXCLUDE         DTSBU521
00029 *                ADMIN ASSESSMENT FROM INTEREST CALCULATION       DTSBU521
00030 *                IF THE EMPLOYER IS SELF-INSURED.                 DTSBU521
00031 *                P2200, P3000.                                    DTSBU521
00032 *                REFERENCE: DIR119              PROGRAMMER: GD    DTSBU521
00033 *                                                                 DTSBU521
00034 *    MM/DD/YYYY  XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX   DTSBU521
00035 *                XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX   DTSBU521
00036 *                REFERENCE: XXXXXXXXXXXXXXX     PROGRAMMER: XXX   DTSBU521
00037 *                                                                 DTSBU521
00038 *                                                                 DTSBU521
00039 *  DESCRIPTION:                                                   DTSBU521
00040 *                                                                 DTSBU521
00041 *      MODIFY THE PAID AMOUNT DEFINED BY L521-APPLIC-ACCT-IND,    DTSBU521
00042 *      L521-APPLIC-YRQ, AND L521-APPLIC-DOC-NO BY                 DTSBU521
00043 *      L521-APPLIC-AMT.                                           DTSBU521
00044 *                                                                 DTSBU521
00045 *      L521-OPTION ALLOWS THE CALLING MODULE TO SIMPLY ASK        DTSBU521
00046 *      WHETHER OR NOT THE REQUEST WOULD BE VALID, BUT NOT         DTSBU521
00047 *      ACTUALLY MODIFY THE MQTR RECORDS.                          DTSBU521
00048 *                                                                 DTSBU521
00049 *      IF THE REQUEST CANNOT BE SATISFIED (BALANCE DUE DEFINED    DTSBU521
00050 *      BY L521-APPLIC-* DOES NOT EXIST, OR WOULD CAUSE PAID AMOUNTDTSBU521
00051 *      TO BECOME NEGATIVE), THEN RETURN L521-NOT-VALID-88.        DTSBU521
00052 *                                                                 DTSBU521
00053 *      THE INTEREST CHARGED AMOUNT MAY BE CHANGED AS A RESULT OF  DTSBU521
00054 *      CHANGES TO TAX PAID.                                       DTSBU521
00055 *                                                                 DTSBU521
00056 *                                                                 DTSBU521
00057 *      MASTER FILE RECORDS READ:                                  DTSBU521
00058 *                                                                 DTSBU521
00059 *        MQTR                                                     DTSBU521
00060 *        MPAY                                                     DTSBU521
00061 *                                                                 DTSBU521
00062 *                                                                 DTSBU521
00063 *      MASTER FILE RECORDS UPDATED:                               DTSBU521
00064 *                                                                 DTSBU521
00065 *        MQTR (REWRITE)                                           DTSBU521
00066 *                                                                 DTSBU521
00067 *                                                                 DTSBU521
00068 *      REPORT RECORDS WRITTEN:                                    DTSBU521
00069 *                                                                 DTSBU521
00070 *        R907  ERROR.                                             DTSBU521
00071 *                                                                 DTSBU521
00072 *                                                                 DTSBU521
00073 *      MODULES CALLED:                                            DTSBU521
00074 *                                                                 DTSBU521
00075 *        DTSBU522 RETURN A PAID AMOUNT TO UNAPPLIED CREDIT.       DTSBU521
00076 *        DTSBU529 PAY-DSTRB CONSOLIDATION.                        DTSBU521
00077 *        DTSBU541 MODIFY A SPECIFIED CHARGED, WAIVED, TOLERATED,  DTSBU521
00078 *                 OR WRITE-OFF AMOUNT.                            DTSBU521
00079 *        DTSBU549 JOURNALING/BATCH DETAIL LISTING.                DTSBU521
00080 *        DTSBU590 EMPLOYER CLEANUP.                               DTSBU521
00081 *        DTSBU910 MASTER FILE I/O.                                DTSBU521
00082 *        DTSBU946 VARIABLE LENGTH RECORD SEQUENTIAL OUTPUT 1.     DTSBU521
00083 *                                                                 DTSBU521
00084 *                                                                 DTSBU521
00085 *****                                                             DTSBU521
00086      SKIP3                                                        DTSBU521
00087  ENVIRONMENT DIVISION.                                            DTSBU521
00088      EJECT                                                        DTSBU521
00089  DATA DIVISION.                                                   DTSBU521
00090      SKIP3                                                        DTSBU521
00091  WORKING-STORAGE SECTION.                                         DTSBU521
000915 77  PAN-VALET PICTURE X(24) VALUE '011DTSBU521  11/03/08'.       DTSBU521
00092      SKIP3                                                        DTSBU521
00093  01  WRK-AREA.                                                    DTSBU521
00094      05  WRK-AMT-DISP1               PIC --------9.99.            DTSBU521
00095      05  WRK-AMT-DISP2               PIC --------9.99.            DTSBU521
00096      05  WRK-ABEND-CD                PIC S9(04)  COMP  VALUE +521.DTSBU521
00097                                                                   DTSBU521
00098      05  WRK-MOD-NAME                PIC  X(08)  VALUE 'DTSBU521'.DTSBU521
00099                                                                   DTSBU521
00100      05  FIRST-TIME-IND                  PIC  X(01)    VALUE 'Y'. DTSBU521
00101                                                                   DTSBU521
00102                                                                   DTSBU521
00103      05  WRK-NULL-DOC-NO.                                         DTSBU521
00104          10  WRK-NULL-BATCH-NO           PIC S9(05)       COMP-3. DTSBU521
00105          10  WRK-NULL-ITEM-NO            PIC S9(03)       COMP-3. DTSBU521
00106                                                                   DTSBU521
00107                                                                   DTSBU521
00108      05  WRK-MPRF-CREDIT-AMT             PIC S9(09)V9(02) COMP-3. DTSBU521
00109                                                                   DTSBU521
00110      05  WRK-MPRF-BALANCE-AMT            PIC S9(09)V9(02) COMP-3. DTSBU521
00111                                                                   DTSBU521
00112      05  WRK-MQTR-BALANCE-AMT            PIC S9(09)V9(02) COMP-3. DTSBU521
00113                                                                   DTSBU521
00114      05  WRK-MQTR-PAID-AMT               PIC S9(09)V9(02) COMP-3. DTSBU521
00115                                                                   DTSBU521
00116                                                                   DTSBU521
00117      05  HOLD-MQTR-SUB                   PIC S9(04)       COMP.   DTSBU521
00118                                                                   DTSBU521
00119      05  HOLD-INT-SUB                    PIC S9(04)       COMP.   DTSBU521
00120                                                                   DTSBU521
00121 *****05  HOLD-PEN-SUB                    PIC S9(04)       COMP.   DTSBU521
00122                                                                   DTSBU521
00123      05  HOLD-TAX-SUB                    PIC S9(04)       COMP.   DTSBU521
00124                                                                   DTSBU521
00125      05  HOLD-ACCT-SUB                   PIC S9(04)       COMP.   DTSBU521
00126                                                                   DTSBU521
00127                                                                   DTSBU521
00128      05  ACCT-CRUNCH-COMPLETE-IND        PIC  X(01).              DTSBU521
00129                                                                   DTSBU521
00130      05  ACCT-SUB                        PIC S9(04)       COMP.   DTSBU521
00131                                                                   DTSBU521
00132      05  ACCT-SUB1                       PIC S9(04)       COMP.   DTSBU521
00133                                                                   DTSBU521
00134      05  ACCT-SUB2                       PIC S9(04)       COMP.   DTSBU521
00135                                                                   DTSBU521
00136                                                                   DTSBU521
00137      05  WRK-INT-CHARGED-AMT             PIC S9(09)V9(02) COMP-3. DTSBU521
00138                                                                   DTSBU521
00139 *****05  WRK-PEN-CHARGED-AMT             PIC S9(09)V9(02) COMP-3. DTSBU521
00140                                                                   DTSBU521
00141      05  WRK-TAX-CHARGED-AMT             PIC S9(09)V9(02) COMP-3. DTSBU521
00142                                                                   DTSBU521
00143      05  WRK-MQTR-TOT-BALANCE-AMT        PIC S9(09)V9(02) COMP-3. DTSBU521
00144                                                                   DTSBU521
00145      05  WRK-TAX-PAID-AMT                PIC S9(09)V9(02) COMP-3. DTSBU521
00146      EJECT                                                        DTSBU521
00147  01  HOLD-AREA.                                                   DTSBU521
00148      05  HOLD-EMP-NO                     PIC S9(07)  COMP-3.      DTSBU521
00149                                                                   DTSBU521
00150      05  HOLD-YRQ-AREA.                                           DTSBU521
00151          10  HOLD-YRQ-INDS OCCURS 400 TIMES.                      DTSBU521
00152              15  HOLD-YRQ-MSG1-IND       PIC  X(01).              DTSBU521
00153                  88  HOLD-YRQ-MSG1-SENT-88      VALUE 'Y'.        DTSBU521
00154                  88  HOLD-YRQ-MSG1-NOT-SENT-88  VALUE ' '.        DTSBU521
00155              15  HOLD-YRQ-MSG2-IND       PIC  X(01).              DTSBU521
00156                  88  HOLD-YRQ-MSG2-SENT-88      VALUE 'Y'.        DTSBU521
00157                  88  HOLD-YRQ-MSG2-NOT-SENT-88  VALUE ' '.        DTSBU521
00158              15  HOLD-YRQ-MSG3-IND       PIC  X(01).              DTSBU521
00159                  88  HOLD-YRQ-MSG3-SENT-88      VALUE 'Y'.        DTSBU521
00160                  88  HOLD-YRQ-MSG3-NOT-SENT-88  VALUE ' '.        DTSBU521
00161              15  HOLD-YRQ-MSG4-IND       PIC  X(01).              DTSBU521
00162                  88  HOLD-YRQ-MSG4-SENT-88      VALUE 'Y'.        DTSBU521
00163                  88  HOLD-YRQ-MSG4-NOT-SENT-88  VALUE ' '.        DTSBU521
00164              15  HOLD-YRQ-MSG5-IND       PIC  X(01).              DTSBU521
00165                  88  HOLD-YRQ-MSG5-SENT-88      VALUE 'Y'.        DTSBU521
00166                  88  HOLD-YRQ-MSG5-NOT-SENT-88  VALUE ' '.        DTSBU521
00167              15  HOLD-YRQ-MSG6-IND       PIC  X(01).              DTSBU521
00168                  88  HOLD-YRQ-MSG6-SENT-88      VALUE 'Y'.        DTSBU521
00169                  88  HOLD-YRQ-MSG6-NOT-SENT-88  VALUE ' '.        DTSBU521
00170      EJECT                                                        DTSBU521
00171  01  MSG-TABLE.                                                   DTSBU521
00172      05  MSG1-MANUAL-INT.                                         DTSBU521
00173          10  MSG1-ID.                                             DTSBU521
00174              15  MSG1-ID1    PIC  X(08)  VALUE 'DTSBU521'.        DTSBU521
00175              15  MSG1-ID2    PIC  X(03)  VALUE '356'.             DTSBU521
00176          10  MSG1-SHORT-TEXT PIC  X(20)  VALUE 'MAN INT QTR PD'.  DTSBU521
00177          10  MSG1-LONG-TEXT.                                      DTSBU521
00178              15  FILLER      PIC  X(30)                           DTSBU521
00179                    VALUE 'TAX PAID MODIFIED IN A MANUAL '.        DTSBU521
00180              15  FILLER      PIC  X(25)                           DTSBU521
00181                    VALUE 'INTEREST QUARTER.  YRQ = '.             DTSBU521
00182              15  MSG1-SLASHED-YRQ        PIC  X(04).              DTSBU521
00183                                                                   DTSBU521
00184 *****05  MSG2-MANUAL-PEN.                                         DTSBU521
00185 *********10  MSG2-ID.                                             DTSBU521
00186 *************15  MSG2-ID1    PIC  X(08)  VALUE 'DTSBU521'.        DTSBU521
00187 *************15  MSG2-ID2    PIC  X(03)  VALUE '357'.             DTSBU521
00188 *********10  MSG2-SHORT-TEXT PIC  X(20)  VALUE 'MAN PEN QTR PD'.  DTSBU521
00189 *********10  MSG2-LONG-TEXT.                                      DTSBU521
00190 *************15  FILLER      PIC  X(30)                           DTSBU521
00191 *******************VALUE 'TAX PAID MODIFIED IN A MANUAL '.        DTSBU521
00192 *************15  FILLER      PIC  X(25)                           DTSBU521
00193 *******************VALUE 'PENALTY QUARTER.   YRQ = '.             DTSBU521
00194 *************15  MSG2-SLASHED-YRQ        PIC  X(04).              DTSBU521
00195                                                                   DTSBU521
00196      05  MSG3-AUTO-INT-WAIVE-INCR.                                DTSBU521
00197          10  MSG3-ID.                                             DTSBU521
00198              15  MSG3-ID1    PIC  X(08)  VALUE 'DTSBU521'.        DTSBU521
00199              15  MSG3-ID2    PIC  X(11)  VALUE '358'.             DTSBU521
00200          10  MSG3-SHORT-TEXT PIC  X(20)  VALUE 'AUTO INT WAIVE'.  DTSBU521
00201          10  MSG3-LONG-TEXT.                                      DTSBU521
00202              15  FILLER      PIC  X(30)                           DTSBU521
00203                    VALUE 'INTEREST WAIVED INCREASED AUTO'.        DTSBU521
00204              15  FILLER      PIC  X(25)                           DTSBU521
00205                    VALUE 'MATICALLY.         YRQ = '.             DTSBU521
00206              15  MSG3-SLASHED-YRQ        PIC  X(04).              DTSBU521
00207                                                                   DTSBU521
00208 *****05  MSG4-AUTO-PEN-WAIVE-INCR.                                DTSBU521
00209 *********10  MSG4-ID.                                             DTSBU521
00210 *************15  MSG4-ID1    PIC  X(08)  VALUE 'DTSBU521'.        DTSBU521
00211 *************15  MSG4-ID2    PIC  X(11)  VALUE '359'.             DTSBU521
00212 *********10  MSG4-SHORT-TEXT PIC  X(20)  VALUE 'AUTO PEN WAIVE'.  DTSBU521
00213 *********10  MSG4-LONG-TEXT.                                      DTSBU521
00214 *************15  FILLER      PIC  X(30)                           DTSBU521
00215 *******************VALUE 'PENALTY WAIVED INCREASED AUTOM'.        DTSBU521
00216 *************15  FILLER      PIC  X(25)                           DTSBU521
00217 *******************VALUE 'ATICALLY.          YRQ = '.             DTSBU521
00218 *************15  MSG4-SLASHED-YRQ        PIC  X(04).              DTSBU521
00219                                                                   DTSBU521
00220      05  MSG5-AUTO-INT-WAIVE-DECR.                                DTSBU521
00221          10  MSG5-ID.                                             DTSBU521
00222              15  MSG5-ID1    PIC  X(08)  VALUE 'DTSBU521'.        DTSBU521
00223              15  MSG5-ID2    PIC  X(11)  VALUE '360'.             DTSBU521
00224          10  MSG5-SHORT-TEXT PIC  X(20)  VALUE 'AUTO INT WAIVE'.  DTSBU521
00225          10  MSG5-LONG-TEXT.                                      DTSBU521
00226              15  FILLER      PIC  X(30)                           DTSBU521
00227                    VALUE 'INTEREST WAIVED DECREASED AUTO'.        DTSBU521
00228              15  FILLER      PIC  X(25)                           DTSBU521
00229                    VALUE 'MATICALLY.         YRQ = '.             DTSBU521
00230              15  MSG5-SLASHED-YRQ        PIC  X(04).              DTSBU521
00231                                                                   DTSBU521
00232 *****05  MSG6-AUTO-PEN-WAIVE-DECR.                                DTSBU521
00233 *********10  MSG6-ID.                                             DTSBU521
00234 *************15  MSG6-ID1    PIC  X(08)  VALUE 'DTSBU521'.        DTSBU521
00235 *************15  MSG6-ID2    PIC  X(11)  VALUE '361'.             DTSBU521
00236 *********10  MSG6-SHORT-TEXT PIC  X(20)  VALUE 'AUTO PEN WAIVE'.  DTSBU521
00237 *********10  MSG6-LONG-TEXT.                                      DTSBU521
00238 *************15  FILLER      PIC  X(30)                           DTSBU521
00239 *******************VALUE 'PENALTY WAIVED DECREASED AUTOM'.        DTSBU521
00240 *************15  FILLER      PIC  X(25)                           DTSBU521
00241 *******************VALUE 'ATICALLY.          YRQ = '.             DTSBU521
00242 *************15  MSG6-SLASHED-YRQ        PIC  X(04).              DTSBU521
00243      EJECT                                                        DTSBU521
00244  01  R907-REC.                                                    DTSBU521
00245  ++INCLUDE DTSIR907                                               DTSBU521
00246      EJECT                                                        DTSBU521
00247  01  L910-LINK-AREA.                                              DTSBU521
00248  ++INCLUDE DTSIL910                                               DTSBU521
00249      SKIP3                                                        DTSBU521
00250  01  MSKL-REC.                                                    DTSBU521
00251  ++INCLUDE DTSIMSKL                                               DTSBU521
00252      SKIP3                                                        DTSBU521
00253  01  MQTR-REC.                                                    DTSBU521
00254  ++INCLUDE DTSIMQTR                                               DTSBU521
00255      EJECT                                                        DTSBU521
00256  01  L004-LINK-AREA.                                              DTSBU521
00257  ++INCLUDE DTSIL004                                               DTSBU521
00258      SKIP3                                                        DTSBU521
00259  01  L101-LINK-AREA.                                              DTSBU521
00260  ++INCLUDE DTSIL101                                               DTSBU521
00261      SKIP3                                                        DTSBU521
00262  01  L109-LINK-AREA.                                              DTSBU521
00263  ++INCLUDE DTSIL109                                               DTSBU521
00264      SKIP3                                                        DTSBU521
00265  01  L522-LINK-AREA.                                              DTSBU521
00266  ++INCLUDE DTSIL522                                               DTSBU521
00267      SKIP3                                                        DTSBU521
00268  01  L541-LINK-AREA.                                              DTSBU521
00269  ++INCLUDE DTSIL541                                               DTSBU521
00270      SKIP3                                                        DTSBU521
00271  01  L549-LINK-AREA.                                              DTSBU521
00272  ++INCLUDE DTSIL549                                               DTSBU521
00273      SKIP3                                                        DTSBU521
00274  01  L590-LINK-AREA.                                              DTSBU521
00275  ++INCLUDE DTSIL590                                               DTSBU521
00276      EJECT                                                        DTSBU521
00277  01  CACT-LITERALS.                                               DTSBU521
00278  ++INCLUDE DTSICACT                                               DTSBU521
00279      SKIP3                                                        DTSBU521
00280  01  MMAX-LITERALS.                                               DTSBU521
00281  ++INCLUDE DTSIMMAX                                               DTSBU521
00282      EJECT                                                        DTSBU521
00283  LINKAGE SECTION.                                                 DTSBU521
00284      SKIP3                                                        DTSBU521
00285  01  L521-LINK-AREA.                                              DTSBU521
00286  ++INCLUDE DTSIL521                                               DTSBU521
00287      EJECT                                                        DTSBU521
00288  01  LBCM-LINK-AREA.                                              DTSBU521
00289  ++INCLUDE DTSILBCM                                               DTSBU521
00290      EJECT                                                        DTSBU521
00291  01  MPRF-REC.                                                    DTSBU521
00292  ++INCLUDE DTSIMPRF                                               DTSBU521
00293      EJECT                                                        DTSBU521
00294  PROCEDURE DIVISION USING L521-LINK-AREA                          DTSBU521
00295                           LBCM-LINK-AREA                          DTSBU521
00296                           MPRF-REC.                               DTSBU521
00297                                                                   DTSBU521
00298 *&                                                                DTSBU521
00299 *     IF MPRF-EMP-NO = 145516                                     DTSBU521
00300 *        MOVE MPRF-TOT-BALANCE-AMT TO WRK-AMT-DISP1               DTSBU521
00301 *        MOVE MPRF-TOT-CREDIT-AMT  TO WRK-AMT-DISP2               DTSBU521
00302 *        DISPLAY 'BU521 PROC  ' MPRF-EMP-NO                       DTSBU521
00303 *           '  BAL ' WRK-AMT-DISP1                                DTSBU521
00304 *           '  CR ' WRK-AMT-DISP2                                 DTSBU521
00305 *     END-IF.                                                     DTSBU521
00306 *&                                                                DTSBU521
00307                                                                   DTSBU521
00308                                                                   DTSBU521
00309      IF FIRST-TIME-IND = 'Y'                                      DTSBU521
00310          PERFORM I0000-FIRST-TIME THRU I0000-EXIT                 DTSBU521
00311          MOVE 'N' TO FIRST-TIME-IND.                              DTSBU521
00312                                                                   DTSBU521
00313                                                                   DTSBU521
00314      PERFORM P0000-PROCESS THRU P0000-EXIT.                       DTSBU521
00315                                                                   DTSBU521
00316                                                                   DTSBU521
00317      GOBACK.                                                      DTSBU521
00318      EJECT                                                        DTSBU521
00319  I0000-FIRST-TIME.                                                DTSBU521
00320      MOVE LBCM-TRACE-IND TO L910-TRACE-IND.                       DTSBU521
00321                                                                   DTSBU521
00322      MOVE WRK-MOD-NAME TO L910-MOD-NAME                           DTSBU521
00323                           R907-MODULE-NAME.                       DTSBU521
00324                                                                   DTSBU521
00325      MOVE +0 TO WRK-NULL-BATCH-NO                                 DTSBU521
00326                 WRK-NULL-ITEM-NO.                                 DTSBU521
00327                                                                   DTSBU521
00328      MOVE LENGTH OF R907-REC TO R907-LENGTH.                      DTSBU521
00329                                                                   DTSBU521
00330      PERFORM S109-FIRST-PEN-INT-YRQ   THRU S109-EXIT.             DTSBU521
00331                                                                   DTSBU521
00332      PERFORM P1000-EMP-NO-BREAK THRU P1000-EXIT.                  DTSBU521
00333                                                                   DTSBU521
00334  I0000-EXIT.                                                      DTSBU521
00335      EXIT.                                                        DTSBU521
00336      EJECT                                                        DTSBU521
00337  P0000-PROCESS.                                                   DTSBU521
00338 *&                                                                DTSBU521
00339 *    IF MPRF-EMP-NO = 145516                                      DTSBU521
00340 *       MOVE L521-APPLIC-AMT TO WRK-AMT-DISP1                     DTSBU521
00341 *       DISPLAY ' BU521 P0000  ' MPRF-EMP-NO                      DTSBU521
00342 *         '  YRQ ' L521-APPLIC-YRQ                                DTSBU521
00343 *         '  AMT ' WRK-AMT-DISP1                                  DTSBU521
00344 *         '  IND ' L521-APPLIC-ACCT-IND                           DTSBU521
00345 *    END-IF.                                                      DTSBU521
00346 *&                                                                DTSBU521
00347      IF MPRF-EMP-NO = HOLD-EMP-NO                                 DTSBU521
00348          NEXT SENTENCE                                            DTSBU521
00349      ELSE                                                         DTSBU521
00350          PERFORM P1000-EMP-NO-BREAK THRU P1000-EXIT.              DTSBU521
00351                                                                   DTSBU521
00352      MOVE MPRF-EMP-NO TO R907-EMP-NO.                             DTSBU521
00353                                                                   DTSBU521
00354      MOVE LBCM-TRN-DOC-NO TO L549-TRN-DOC-NO.                     DTSBU521
00355                                                                   DTSBU521
00356      SET L521-VALID-88 TO TRUE.                                   DTSBU521
00357                                                                   DTSBU521
00358      IF L521-CHECK-VALIDITY-88 OR L521-UPDATE-88                  DTSBU521
00359          NEXT SENTENCE                                            DTSBU521
00360      ELSE                                                         DTSBU521
00361          PERFORM S999-ABEND THRU S999-EXIT.                       DTSBU521
00362                                                                   DTSBU521
00363      IF L521-APPLIC-ACCT-IND = CACT-ACCT-CREDIT                   DTSBU521
00364                                  OR CACT-CR-AVAIL                 DTSBU521
00365                                  OR CACT-CR-WRITE-OFF             DTSBU521
00366                                  OR CACT-CR-TOLER                 DTSBU521
00367          PERFORM S999-ABEND THRU S999-EXIT.                       DTSBU521
00368                                                                   DTSBU521
00369      PERFORM P2100-EDIT THRU P2100-EXIT.                          DTSBU521
00370                                                                   DTSBU521
00371      IF L521-UPDATE-88                                            DTSBU521
00372            AND                                                    DTSBU521
00373         L521-VALID-88                                             DTSBU521
00374          PERFORM P2200-UPDATE THRU P2200-EXIT.                    DTSBU521
00375  P0000-EXIT.                                                      DTSBU521
00376      EXIT.                                                        DTSBU521
00377      SKIP3                                                        DTSBU521
00378  P1000-EMP-NO-BREAK.                                              DTSBU521
00379      MOVE MPRF-EMP-NO TO HOLD-EMP-NO.                             DTSBU521
00380                                                                   DTSBU521
00381      MOVE SPACES TO HOLD-YRQ-AREA.                                DTSBU521
00382  P1000-EXIT.                                                      DTSBU521
00383      EXIT.                                                        DTSBU521
00384      EJECT                                                        DTSBU521
00385  P2100-EDIT.                                                      DTSBU521
00386      PERFORM S1110-READ-MQTR THRU S1110-EXIT.                     DTSBU521
00387                                                                   DTSBU521
00388      IF L910-NO-REC-88                                            DTSBU521
00389      DISPLAY ' BU521 P2100 NO MQTR '                              DTSBU521
00390          SET L521-NOT-VALID-88 TO TRUE                            DTSBU521
00391          GO TO P2100-EXIT.                                        DTSBU521
00392                                                                   DTSBU521
00393                                                                   DTSBU521
00394      MOVE +0 TO HOLD-MQTR-SUB.                                    DTSBU521
00395                                                                   DTSBU521
00396      PERFORM                                                      DTSBU521
00397        VARYING MQTR-ACCT-IDX FROM 1 BY 1                          DTSBU521
00398        UNTIL MQTR-ACCT-IDX > MQTR-ACCT-CNT                        DTSBU521
00399          IF MQTR-ACCT-IND (MQTR-ACCT-IDX) = L521-APPLIC-ACCT-IND  DTSBU521
00400              SET HOLD-MQTR-SUB TO MQTR-ACCT-IDX                   DTSBU521
00401          END-IF                                                   DTSBU521
00402      END-PERFORM.                                                 DTSBU521
00403                                                                   DTSBU521
00404      IF HOLD-MQTR-SUB = +0                                        DTSBU521
00405      DISPLAY ' BU521 P2100 APPLIC ACCT NOT FOUND '                DTSBU521
00406          SET L521-NOT-VALID-88 TO TRUE                            DTSBU521
00407          GO TO P2100-EXIT.                                        DTSBU521
00408                                                                   DTSBU521
00409                                                                   DTSBU521
00410      COMPUTE WRK-MPRF-BALANCE-AMT                                 DTSBU521
00411        = MPRF-TOT-BALANCE-AMT - L521-APPLIC-AMT.                  DTSBU521
00412                                                                   DTSBU521
00413      COMPUTE WRK-MQTR-BALANCE-AMT                                 DTSBU521
00414        = MQTR-BALANCE-AMT (HOLD-MQTR-SUB) - L521-APPLIC-AMT.      DTSBU521
00415                                                                   DTSBU521
00416      COMPUTE WRK-MQTR-PAID-AMT                                    DTSBU521
00417        = MQTR-PAID-AMT (HOLD-MQTR-SUB) + L521-APPLIC-AMT.         DTSBU521
00418                                                                   DTSBU521
00419      IF (WRK-MPRF-BALANCE-AMT < +0)                               DTSBU521
00420              OR                                                   DTSBU521
00421         (WRK-MQTR-BALANCE-AMT < +0)                               DTSBU521
00422              OR                                                   DTSBU521
00423         (WRK-MQTR-PAID-AMT < +0)                                  DTSBU521
00424      DISPLAY ' BU521 P2100 BAL < 0'                               DTSBU521
00425          SET L521-NOT-VALID-88 TO TRUE                            DTSBU521
00426          GO TO P2100-EXIT.                                        DTSBU521
00427                                                                   DTSBU521
00428      IF L521-APPLIC-ACCT-IND = CACT-ACCT-UI                       DTSBU521
00429                                  OR CACT-ACCT-SUR                 DTSBU521
00430          PERFORM P2120-EDIT-TAX THRU P2120-EXIT.                  DTSBU521
00431  P2100-EXIT.                                                      DTSBU521
00432      EXIT.                                                        DTSBU521
00433      SKIP3                                                        DTSBU521
00434  P2120-EDIT-TAX.                                                  DTSBU521
00435      IF (MQTR-TAX-DUE-DATE = +0)                                  DTSBU521
00436              OR                                                   DTSBU521
00437         (L521-RECEIVED-DATE = +0)                                 DTSBU521
00438      DISPLAY ' BU521 P2120 DUE OR RCVD = 0'                       DTSBU521
00439          SET L521-NOT-VALID-88 TO TRUE                            DTSBU521
00440          GO TO P2120-EXIT.                                        DTSBU521
00441  P2120-EXIT.                                                      DTSBU521
00442      EXIT.                                                        DTSBU521
00443      EJECT                                                        DTSBU521
00444  P2200-UPDATE.                                                    DTSBU521
00445 **   DISPLAY ' BU521 P2200-UPD1 ' MPRF-EMP-NO                     DTSBU521
00446      COMPUTE MPRF-TOT-BALANCE-AMT                                 DTSBU521
00447        = MPRF-TOT-BALANCE-AMT - L521-APPLIC-AMT.                  DTSBU521
00448                                                                   DTSBU521
00449      COMPUTE MQTR-BALANCE-AMT (HOLD-MQTR-SUB)                     DTSBU521
00450        = MQTR-BALANCE-AMT (HOLD-MQTR-SUB) - L521-APPLIC-AMT.      DTSBU521
00451                                                                   DTSBU521
00452      COMPUTE MQTR-PAID-AMT (HOLD-MQTR-SUB)                        DTSBU521
00453        = MQTR-PAID-AMT (HOLD-MQTR-SUB) + L521-APPLIC-AMT.         DTSBU521
00454                                                                   DTSBU521
00455      MOVE LBCM-CURR-RUN-DATE TO MQTR-CHNG-DATE.                   DTSBU521
00456                                                                   DTSBU521
00457                                                                   DTSBU521
00458      MOVE MQTR-YRQ TO L549-DELTA-YRQ.                             DTSBU521
00459                                                                   DTSBU521
00460      MOVE MQTR-ACCT-IND (HOLD-MQTR-SUB) TO L549-DELTA-ACCT-IND.   DTSBU521
00461                                                                   DTSBU521
00462      MOVE CACT-CAT-PAID TO L549-DELTA-CAT-IND.                    DTSBU521
00463                                                                   DTSBU521
00464      MOVE L521-APPLIC-AMT TO L549-DELTA-AMT.                      DTSBU521
00465                                                                   DTSBU521
00466      PERFORM S549-MJRN-TABLE THRU S549-EXIT.                      DTSBU521
00467                                                                   DTSBU521
00468 ****************************************************              DTSBU521
00469 * PAYMENTS APPLIED TO ADMINISTRATIVE ASSESSMENT ARE               DTSBU521
00470 * INCLUDED IN THE INTEREST CALCULATION ONLY FOR                   DTSBU521
00471 * RATED EMPLOYERS.                                                DTSBU521
00472 ****************************************************              DTSBU521
00473      IF L521-APPLIC-ACCT-IND = CACT-ACCT-UI                       DTSBU521
00474         PERFORM P2210-MANUAL-INT-CHECK THRU P2210-EXIT            DTSBU521
00475         PERFORM P2220-INT-UPDATE THRU P2220-EXIT                  DTSBU521
00476      ELSE                                                         DTSBU521
00477         IF L521-APPLIC-ACCT-IND = CACT-ACCT-SUR                   DTSBU521
00478         AND MQTR-YRQ >= L109-FIRST-PEN-INT-YRQ                    DTSBU521
00479         AND MPRF-CLASS-RATED-88                                   DTSBU521
00480            PERFORM P2210-MANUAL-INT-CHECK THRU P2210-EXIT         DTSBU521
00481            PERFORM P2220-INT-UPDATE THRU P2220-EXIT               DTSBU521
00482         END-IF                                                    DTSBU521
00483      END-IF.                                                      DTSBU521
00484                                                                   DTSBU521
00485      PERFORM S2200-CRUNCH-ACCT-DATA THRU S2200-EXIT.              DTSBU521
00486                                                                   DTSBU521
00487      PERFORM S1120-REWRITE-MQTR THRU S1120-EXIT.                  DTSBU521
00488  P2200-EXIT.                                                      DTSBU521
00489      EXIT.                                                        DTSBU521
00490      SKIP3                                                        DTSBU521
00491  P2210-MANUAL-INT-CHECK.                                          DTSBU521
00492      IF MQTR-INT-CHARGE-MANUAL-88                                 DTSBU521
00493          MOVE MQTR-YRQ TO L004-QTR-5-9                            DTSBU521
00494          PERFORM S004-FROM-5 THRU S004-EXIT                       DTSBU521
00495          IF HOLD-YRQ-MSG1-NOT-SENT-88 (L004-ABS-QTR)              DTSBU521
00496              SET HOLD-YRQ-MSG1-SENT-88 (L004-ABS-QTR) TO TRUE     DTSBU521
00497              MOVE L004-SLASH-QTR TO MSG1-SLASHED-YRQ              DTSBU521
00498              MOVE MSG1-ID2 TO R907-MSG-ID                         DTSBU521
00499              MOVE MSG1-LONG-TEXT TO R907-MSG-TEXT                 DTSBU521
00500              PERFORM S946-R907-WRITE THRU S946-EXIT.              DTSBU521
00501                                                                   DTSBU521
00502 *****IF MQTR-PEN-CHARGE-MANUAL-88                                 DTSBU521
00503 *********MOVE MQTR-YRQ TO L004-QTR-5-9                            DTSBU521
00504 *********PERFORM S004-FROM-5 THRU S004-EXIT                       DTSBU521
00505 *********IF HOLD-YRQ-MSG2-NOT-SENT-88 (L004-ABS-QTR)              DTSBU521
00506 *************SET HOLD-YRQ-MSG2-SENT-88 (L004-ABS-QTR) TO TRUE     DTSBU521
00507 *************MOVE L004-SLASH-QTR TO MSG2-SLASHED-YRQ              DTSBU521
00508 *************MOVE MSG2-ID2 TO R907-MSG-ID                         DTSBU521
00509 *************MOVE MSG2-LONG-TEXT TO R907-MSG-TEXT                 DTSBU521
00510 *************PERFORM S946-R907-WRITE THRU S946-EXIT.              DTSBU521
00511  P2210-EXIT.                                                      DTSBU521
00512      EXIT.                                                        DTSBU521
00513      SKIP3                                                        DTSBU521
00514  P2220-INT-UPDATE.                                                DTSBU521
00515      MOVE HOLD-MQTR-SUB TO HOLD-TAX-SUB.                          DTSBU521
00516                                                                   DTSBU521
00517      MOVE L521-APPLIC-AMT TO L101-PAID-CHNG.                      DTSBU521
00518                                                                   DTSBU521
00519      MOVE L521-RECEIVED-DATE TO L101-RECEIVED-DATE.               DTSBU521
00520                                                                   DTSBU521
00521      MOVE L521-WAIVE-INT-IND TO L101-WAIVE-INT-IND.               DTSBU521
00522                                                                   DTSBU521
00523 *****MOVE L521-WAIVE-PEN-IND TO L101-WAIVE-PEN-IND.               DTSBU521
00524                                                                   DTSBU521
00525      MOVE MQTR-TAX-DUE-DATE TO L101-TAX-DUE-DATE.                 DTSBU521
00526                                                                   DTSBU521
00527 *****MOVE +0 TO L101-PEN-CHARGED-AMT.                             DTSBU521
00528                                                                   DTSBU521
00529 *****PERFORM                                                      DTSBU521
00530 *******VARYING MQTR-ACCT-IDX FROM 1 BY 1                          DTSBU521
00531 *******UNTIL MQTR-ACCT-IDX > MQTR-ACCT-CNT                        DTSBU521
00532 *********IF MQTR-ACCT-PEN-88 (MQTR-ACCT-IDX)                      DTSBU521
00533 *************ADD MQTR-CHARGED-AMT (MQTR-ACCT-IDX)                 DTSBU521
00534 **************TO L101-PEN-CHARGED-AMT                             DTSBU521
00535 *********END-IF                                                   DTSBU521
00536 *****END-PERFORM.                                                 DTSBU521
00537                                                                   DTSBU521
00538      MOVE MQTR-INT-AREA TO L101-INT-AREA.                         DTSBU521
00539                                                                   DTSBU521
00540      PERFORM S101-PER-MONTH-NO THRU S101-EXIT.                    DTSBU521
00541                                                                   DTSBU521
00542      MOVE +0 TO HOLD-INT-SUB.                                     DTSBU521
00543 ****************HOLD-PEN-SUB.                                     DTSBU521
00544                                                                   DTSBU521
00545      PERFORM                                                      DTSBU521
00546        VARYING MQTR-ACCT-IDX FROM 1 BY 1                          DTSBU521
00547        UNTIL MQTR-ACCT-IDX > MQTR-ACCT-CNT                        DTSBU521
00548          IF MQTR-ACCT-INT-88 (MQTR-ACCT-IDX)                      DTSBU521
00549              SET HOLD-INT-SUB TO MQTR-ACCT-IDX                    DTSBU521
00550          END-IF                                                   DTSBU521
00551 *********IF MQTR-ACCT-PEN-88 (MQTR-ACCT-IDX)                      DTSBU521
00552 *************SET HOLD-PEN-SUB TO MQTR-ACCT-IDX                    DTSBU521
00553 *********END-IF                                                   DTSBU521
00554      END-PERFORM.                                                 DTSBU521
00555                                                                   DTSBU521
00556      IF HOLD-INT-SUB = +0                                         DTSBU521
00557          PERFORM P2222-ESTB-ACCT-INT THRU P2222-EXIT.             DTSBU521
00558                                                                   DTSBU521
00559      PERFORM P3000-INTEREST THRU P3000-EXIT.                      DTSBU521
00560                                                                   DTSBU521
00561 *****IF HOLD-PEN-SUB = +0                                         DTSBU521
00562 *********PERFORM P2223-ESTB-ACCT-PEN THRU P2223-EXIT.             DTSBU521
00563                                                                   DTSBU521
00564 *****PERFORM P4000-PENALTY THRU P4000-EXIT.                       DTSBU521
00565  P2220-EXIT.                                                      DTSBU521
00566      EXIT.                                                        DTSBU521
00567      SKIP3                                                        DTSBU521
00568  P2222-ESTB-ACCT-INT.                                             DTSBU521
00569      IF MQTR-ACCT-CNT NOT < MMAX-QTR-ACCT-MAX                     DTSBU521
00570          PERFORM S999-ABEND THRU S999-EXIT.                       DTSBU521
00571                                                                   DTSBU521
00572      ADD +1 TO MQTR-ACCT-CNT.                                     DTSBU521
00573                                                                   DTSBU521
00574      MOVE MQTR-ACCT-CNT TO HOLD-INT-SUB.                          DTSBU521
00575                                                                   DTSBU521
00576      MOVE CACT-ACCT-INT TO MQTR-ACCT-IND (MQTR-ACCT-CNT).         DTSBU521
00577                                                                   DTSBU521
00578      MOVE +0 TO MQTR-CHARGED-AMT (MQTR-ACCT-CNT)                  DTSBU521
00579                 MQTR-PAID-AMT (MQTR-ACCT-CNT)                     DTSBU521
00580                 MQTR-WAIVED-AMT (MQTR-ACCT-CNT)                   DTSBU521
00581                 MQTR-WRITTEN-OFF-AMT (MQTR-ACCT-CNT)              DTSBU521
00582                 MQTR-TOLER-AMT (MQTR-ACCT-CNT)                    DTSBU521
00583                 MQTR-BALANCE-AMT (MQTR-ACCT-CNT).                 DTSBU521
00584  P2222-EXIT.                                                      DTSBU521
00585      EXIT.                                                        DTSBU521
00586      SKIP3                                                        DTSBU521
00587 *P2223-ESTB-ACCT-PEN.                                             DTSBU521
00588 *****IF MQTR-ACCT-CNT NOT < MMAX-QTR-ACCT-MAX                     DTSBU521
00589 *********PERFORM S999-ABEND THRU S999-EXIT.                       DTSBU521
00590                                                                   DTSBU521
00591 *****ADD +1 TO MQTR-ACCT-CNT.                                     DTSBU521
00592 *****MOVE MQTR-ACCT-CNT TO HOLD-PEN-SUB.                          DTSBU521
00593 *****MOVE CACT-ACCT-PEN TO MQTR-ACCT-IND (MQTR-ACCT-CNT).         DTSBU521
00594 *****MOVE +0 TO MQTR-CHARGED-AMT (MQTR-ACCT-CNT)                  DTSBU521
00595 ****************MQTR-PAID-AMT (MQTR-ACCT-CNT)                     DTSBU521
00596 ****************MQTR-WAIVED-AMT (MQTR-ACCT-CNT)                   DTSBU521
00597 ****************MQTR-WRITTEN-OFF-AMT (MQTR-ACCT-CNT)              DTSBU521
00598 ****************MQTR-TOLER-AMT (MQTR-ACCT-CNT)                    DTSBU521
00599 ****************MQTR-BALANCE-AMT (MQTR-ACCT-CNT).                 DTSBU521
00600 *P2223-EXIT.                                                      DTSBU521
00601 *****EXIT.                                                        DTSBU521
00602      EJECT                                                        DTSBU521
00603  P3000-INTEREST.                                                  DTSBU521
00604 *****                                                             DTSBU521
00605 *    THIS CODE ASSUMES THAT IF L101-INT-CHARGE-CHNG NOT > +0,     DTSBU521
00606 *    THEN L101-INT-WAIVE-CHNG IS EQUAL TO ZERO.                   DTSBU521
00607 *                                                                 DTSBU521
00608 *    THIS CODE ASSUMES THAT IF L101-INT-CHARGE-CHNG > +0, THEN    DTSBU521
00609 *    L101-INT-WAIVE-CHNG WILL BE >= 0 AND <= L101-INT-CHARGE-CHNG.DTSBU521
00610 *****                                                             DTSBU521
00611                                                                   DTSBU521
00612      IF MQTR-INT-CHARGE-MANUAL-88                                 DTSBU521
00613          GO TO P3000-EXIT.                                        DTSBU521
00614                                                                   DTSBU521
00615      MOVE +0 TO WRK-TAX-CHARGED-AMT                               DTSBU521
00616                 WRK-TAX-PAID-AMT.                                 DTSBU521
00617                                                                   DTSBU521
00618 **********************************************************        DTSBU521
00619 *  UI TAX AND SUR TAX IS SUBJECT TO PENALTY                       DTSBU521
00620 **********************************************************        DTSBU521
00621      PERFORM                                                      DTSBU521
00622        VARYING MQTR-ACCT-IDX FROM 1 BY 1                          DTSBU521
00623        UNTIL MQTR-ACCT-IDX > MQTR-ACCT-CNT                        DTSBU521
00624          IF MQTR-ACCT-UI-88 (MQTR-ACCT-IDX)                       DTSBU521
00625              ADD MQTR-CHARGED-AMT (MQTR-ACCT-IDX)                 DTSBU521
00626               TO WRK-TAX-CHARGED-AMT                              DTSBU521
00627              ADD MQTR-PAID-AMT (MQTR-ACCT-IDX)                    DTSBU521
00628               TO WRK-TAX-PAID-AMT                                 DTSBU521
00629          END-IF                                                   DTSBU521
00630                                                                   DTSBU521
00631          IF MQTR-ACCT-SUR-88 (MQTR-ACCT-IDX)                      DTSBU521
00632          AND MQTR-YRQ >= L109-FIRST-PEN-INT-YRQ                   DTSBU521
00633          AND MPRF-CLASS-RATED-88                                  DTSBU521
00634             ADD MQTR-CHARGED-AMT (MQTR-ACCT-IDX)                  DTSBU521
00635                TO WRK-TAX-CHARGED-AMT                             DTSBU521
00636             ADD MQTR-PAID-AMT (MQTR-ACCT-IDX)                     DTSBU521
00637                TO WRK-TAX-PAID-AMT                                DTSBU521
00638          END-IF                                                   DTSBU521
00639      END-PERFORM.                                                 DTSBU521
00640                                                                   DTSBU521
00641      IF L101-INT-CHARGE-CHNG = +0                                 DTSBU521
00642          PERFORM P3100-NULL-INT-CHARGED THRU P3100-EXIT           DTSBU521
00643      ELSE                                                         DTSBU521
00644      IF L101-INT-CHARGE-CHNG < +0                                 DTSBU521
00645          PERFORM P3300-DECR-INT-CHARGED THRU P3300-EXIT           DTSBU521
00646      ELSE                                                         DTSBU521
00647          PERFORM P3200-INCR-INT-CHARGED THRU P3200-EXIT.          DTSBU521
00648  P3000-EXIT.                                                      DTSBU521
00649      EXIT.                                                        DTSBU521
00650      SKIP3                                                        DTSBU521
00651  P3100-NULL-INT-CHARGED.                                          DTSBU521
00652      IF WRK-TAX-PAID-AMT > +0                                     DTSBU521
00653          GO TO P3100-EXIT.                                        DTSBU521
00654                                                                   DTSBU521
00655      IF MQTR-CHARGED-AMT (HOLD-INT-SUB) = +0                      DTSBU521
00656          GO TO P3100-EXIT.                                        DTSBU521
00657                                                                   DTSBU521
00658      COMPUTE L541-AMT = MQTR-CHARGED-AMT (HOLD-INT-SUB) * -1.     DTSBU521
00659                                                                   DTSBU521
00660      MOVE HOLD-INT-SUB TO L541-ACCT-SUB.                          DTSBU521
00661                                                                   DTSBU521
00662      MOVE CACT-CAT-CHARGED TO L541-CAT-IND.                       DTSBU521
00663                                                                   DTSBU521
00664      PERFORM S541-MODIFY-AMT THRU S541-EXIT.                      DTSBU521
00665                                                                   DTSBU521
00666      MOVE HOLD-INT-SUB TO HOLD-ACCT-SUB.                          DTSBU521
00667                                                                   DTSBU521
00668      PERFORM P5000-NEGATIVE-BALANCE THRU P5000-EXIT.              DTSBU521
00669  P3100-EXIT.                                                      DTSBU521
00670      EXIT.                                                        DTSBU521
00671      SKIP3                                                        DTSBU521
00672  P3200-INCR-INT-CHARGED.                                          DTSBU521
00673      MOVE L101-INT-CHARGE-CHNG TO L541-AMT.                       DTSBU521
00674                                                                   DTSBU521
00675      MOVE HOLD-INT-SUB TO L541-ACCT-SUB.                          DTSBU521
00676                                                                   DTSBU521
00677      MOVE CACT-CAT-CHARGED TO L541-CAT-IND.                       DTSBU521
00678                                                                   DTSBU521
00679      PERFORM S541-MODIFY-AMT THRU S541-EXIT.                      DTSBU521
00680                                                                   DTSBU521
00681                                                                   DTSBU521
00682      IF L101-INT-WAIVE-CHNG > +0                                  DTSBU521
00683          MOVE L101-INT-WAIVE-CHNG TO L541-AMT                     DTSBU521
00684          MOVE HOLD-INT-SUB TO L541-ACCT-SUB                       DTSBU521
00685          MOVE CACT-CAT-WAIVED TO L541-CAT-IND                     DTSBU521
00686          PERFORM S541-MODIFY-AMT THRU S541-EXIT                   DTSBU521
00687          IF L101-WAIVE-INT-NO-88                                  DTSBU521
00688              MOVE MQTR-YRQ TO L004-QTR-5-9                        DTSBU521
00689              PERFORM S004-FROM-5 THRU S004-EXIT                   DTSBU521
00690              IF HOLD-YRQ-MSG3-NOT-SENT-88 (L004-ABS-QTR)          DTSBU521
00691                  SET HOLD-YRQ-MSG3-SENT-88 (L004-ABS-QTR) TO TRUE DTSBU521
00692                  MOVE L004-SLASH-QTR TO MSG3-SLASHED-YRQ          DTSBU521
00693                  MOVE MSG3-ID2 TO R907-MSG-ID                     DTSBU521
00694                  MOVE MSG3-LONG-TEXT TO R907-MSG-TEXT             DTSBU521
00695                  PERFORM S946-R907-WRITE THRU S946-EXIT.          DTSBU521
00696                                                                   DTSBU521
00697      IF WRK-TAX-PAID-AMT NOT > +0                                 DTSBU521
00698          COMPUTE L541-AMT = MQTR-CHARGED-AMT (HOLD-INT-SUB)       DTSBU521
00699                                  * -1                             DTSBU521
00700          MOVE HOLD-INT-SUB TO L541-ACCT-SUB                       DTSBU521
00701          MOVE CACT-CAT-CHARGED TO L541-CAT-IND                    DTSBU521
00702          PERFORM S541-MODIFY-AMT THRU S541-EXIT.                  DTSBU521
00703                                                                   DTSBU521
00704      MOVE HOLD-INT-SUB TO HOLD-ACCT-SUB.                          DTSBU521
00705                                                                   DTSBU521
00706      PERFORM P5000-NEGATIVE-BALANCE THRU P5000-EXIT.              DTSBU521
00707  P3200-EXIT.                                                      DTSBU521
00708      EXIT.                                                        DTSBU521
00709      SKIP3                                                        DTSBU521
00710  P3300-DECR-INT-CHARGED.                                          DTSBU521
00711      COMPUTE WRK-INT-CHARGED-AMT                                  DTSBU521
00712        = MQTR-CHARGED-AMT (HOLD-INT-SUB)                          DTSBU521
00713            + L101-INT-CHARGE-CHNG.                                DTSBU521
00714                                                                   DTSBU521
00715      IF WRK-TAX-PAID-AMT NOT > +0                                 DTSBU521
00716          COMPUTE L541-AMT                                         DTSBU521
00717            = MQTR-CHARGED-AMT (HOLD-INT-SUB) * -1                 DTSBU521
00718      ELSE                                                         DTSBU521
00719      IF WRK-INT-CHARGED-AMT < +0                                  DTSBU521
00720          COMPUTE L541-AMT                                         DTSBU521
00721            = MQTR-CHARGED-AMT (HOLD-INT-SUB) * -1                 DTSBU521
00722      ELSE                                                         DTSBU521
00723          MOVE L101-INT-CHARGE-CHNG TO L541-AMT.                   DTSBU521
00724                                                                   DTSBU521
00725      MOVE HOLD-INT-SUB TO L541-ACCT-SUB.                          DTSBU521
00726                                                                   DTSBU521
00727      MOVE CACT-CAT-CHARGED TO L541-CAT-IND.                       DTSBU521
00728                                                                   DTSBU521
00729      PERFORM S541-MODIFY-AMT THRU S541-EXIT.                      DTSBU521
00730                                                                   DTSBU521
00731      MOVE HOLD-INT-SUB TO HOLD-ACCT-SUB.                          DTSBU521
00732                                                                   DTSBU521
00733      PERFORM P5000-NEGATIVE-BALANCE THRU P5000-EXIT.              DTSBU521
00734  P3300-EXIT.                                                      DTSBU521
00735      EXIT.                                                        DTSBU521
00736      EJECT                                                        DTSBU521
00737 *P4000-PENALTY.                                                   DTSBU521
00738 *****                                                             DTSBU521
00739 *    THIS CODE ASSUMES THAT IF L101-PEN-CHARGE-CHNG NOT > +0,     DTSBU521
00740 *    THEN L101-PEN-WAIVE-CHNG IS EQUAL TO ZERO.                   DTSBU521
00741 *                                                                 DTSBU521
00742 *    THIS CODE ASSUMES THAT IF L101-PEN-CHARGE-CHNG > +0, THEN    DTSBU521
00743 *    L101-PEN-WAIVE-CHNG WITH BE >= +0 AND <=                     DTSBU521
00744 *    L101-PEN-CHARGE-CHNG.                                        DTSBU521
00745 *****                                                             DTSBU521
00746                                                                   DTSBU521
00747 *****ADD L101-SUBJ10-CHNG TO MQTR-TAX-PAID-SUBJ10-AMT.            DTSBU521
00748 *****ADD L101-SUBJ15-CHNG TO MQTR-TAX-PAID-SUBJ15-AMT.            DTSBU521
00749                                                                   DTSBU521
00750 *****MOVE +0 TO WRK-TAX-CHARGED-AMT                               DTSBU521
00751 ****************WRK-TAX-PAID-AMT.                                 DTSBU521
00752                                                                   DTSBU521
00753 *****PERFORM                                                      DTSBU521
00754 *******VARYING MQTR-ACCT-IDX FROM 1 BY 1                          DTSBU521
00755 *******UNTIL MQTR-ACCT-IDX > MQTR-ACCT-CNT                        DTSBU521
00756 *********IF MQTR-ACCT-UI-88 (MQTR-ACCT-IDX)                       DTSBU521
00757 *************ADD MQTR-CHARGED-AMT (MQTR-ACCT-IDX)                 DTSBU521
00758 **************TO WRK-TAX-CHARGED-AMT                              DTSBU521
00759 *************ADD MQTR-PAID-AMT (MQTR-ACCT-IDX)                    DTSBU521
00760 **************TO WRK-TAX-PAID-AMT                                 DTSBU521
00761 *********END-IF                                                   DTSBU521
00762 *****END-PERFORM.                                                 DTSBU521
00763                                                                   DTSBU521
00764 *****IF WRK-TAX-PAID-AMT = +0                                     DTSBU521
00765 *********MOVE +0 TO MQTR-TAX-PAID-SUBJ10-AMT                      DTSBU521
00766 ********************MQTR-TAX-PAID-SUBJ15-AMT.                     DTSBU521
00767                                                                   DTSBU521
00768 *****IF MQTR-PEN-CHARGE-MANUAL-88                                 DTSBU521
00769 *********GO TO P4000-EXIT.                                        DTSBU521
00770                                                                   DTSBU521
00771 *****IF L101-PEN-CHARGE-CHNG = +0                                 DTSBU521
00772 *********PERFORM P4100-NULL-PEN-CHARGED THRU P4100-EXIT           DTSBU521
00773 *****ELSE                                                         DTSBU521
00774 *****IF L101-PEN-CHARGE-CHNG < +0                                 DTSBU521
00775 *********PERFORM P4300-DECR-PEN-CHARGED THRU P4300-EXIT           DTSBU521
00776 *****ELSE                                                         DTSBU521
00777 *********PERFORM P4200-INCR-PEN-CHARGED THRU P4200-EXIT.          DTSBU521
00778 *P4000-EXIT.                                                      DTSBU521
00779 *****EXIT.                                                        DTSBU521
00780      SKIP3                                                        DTSBU521
00781 *P4100-NULL-PEN-CHARGED.                                          DTSBU521
00782 *****IF WRK-TAX-PAID-AMT > +0                                     DTSBU521
00783 *********GO TO P4100-EXIT.                                        DTSBU521
00784                                                                   DTSBU521
00785 *****IF MQTR-CHARGED-AMT (HOLD-PEN-SUB) = +0                      DTSBU521
00786 *********GO TO P4100-EXIT.                                        DTSBU521
00787                                                                   DTSBU521
00788 *****COMPUTE L541-AMT = MQTR-CHARGED-AMT (HOLD-PEN-SUB) * -1.     DTSBU521
00789                                                                   DTSBU521
00790 *****MOVE HOLD-PEN-SUB TO L541-ACCT-SUB.                          DTSBU521
00791 *****MOVE CACT-CAT-CHARGED TO L541-CAT-IND.                       DTSBU521
00792 *****PERFORM S541-MODIFY-AMT THRU S541-EXIT.                      DTSBU521
00793                                                                   DTSBU521
00794 *****MOVE HOLD-PEN-SUB TO HOLD-ACCT-SUB.                          DTSBU521
00795 *****PERFORM P5000-NEGATIVE-BALANCE THRU P5000-EXIT.              DTSBU521
00796 *P4100-EXIT.                                                      DTSBU521
00797 *****EXIT.                                                        DTSBU521
00798      SKIP3                                                        DTSBU521
00799 *P4200-INCR-PEN-CHARGED.                                          DTSBU521
00800 *****MOVE L101-PEN-CHARGE-CHNG TO L541-AMT.                       DTSBU521
00801 *****MOVE HOLD-PEN-SUB TO L541-ACCT-SUB.                          DTSBU521
00802 *****MOVE CACT-CAT-CHARGED TO L541-CAT-IND.                       DTSBU521
00803 *****PERFORM S541-MODIFY-AMT THRU S541-EXIT.                      DTSBU521
00804                                                                   DTSBU521
00805 *****IF L101-PEN-WAIVE-CHNG > +0                                  DTSBU521
00806 *********MOVE L101-PEN-WAIVE-CHNG TO L541-AMT                     DTSBU521
00807 *********MOVE HOLD-PEN-SUB TO L541-ACCT-SUB                       DTSBU521
00808 *********MOVE CACT-CAT-WAIVED TO L541-CAT-IND                     DTSBU521
00809 *********PERFORM S541-MODIFY-AMT THRU S541-EXIT                   DTSBU521
00810 *********IF L101-WAIVE-PEN-NO-88                                  DTSBU521
00811 *************MOVE MQTR-YRQ TO L004-QTR-5-9                        DTSBU521
00812 *************PERFORM S004-FROM-5 THRU S004-EXIT                   DTSBU521
00813 *************IF HOLD-YRQ-MSG4-NOT-SENT-88 (L004-ABS-QTR)          DTSBU521
00814 *****************SET HOLD-YRQ-MSG4-SENT-88 (L004-ABS-QTR) TO TRUE DTSBU521
00815 *****************MOVE L004-SLASH-QTR TO MSG4-SLASHED-YRQ          DTSBU521
00816 *****************MOVE MSG4-ID2 TO R907-MSG-ID                     DTSBU521
00817 *****************MOVE MSG4-LONG-TEXT TO R907-MSG-TEXT             DTSBU521
00818 *****************PERFORM S946-R907-WRITE THRU S946-EXIT.          DTSBU521
00819                                                                   DTSBU521
00820 *****IF WRK-TAX-PAID-AMT NOT > +0                                 DTSBU521
00821 *********COMPUTE L541-AMT                                         DTSBU521
00822 ***********= MQTR-CHARGED-AMT (HOLD-PEN-SUB) * -1                 DTSBU521
00823 *********MOVE HOLD-PEN-SUB TO L541-ACCT-SUB                       DTSBU521
00824 *********MOVE CACT-CAT-CHARGED TO L541-CAT-IND                    DTSBU521
00825 *********PERFORM S541-MODIFY-AMT THRU S541-EXIT.                  DTSBU521
00826                                                                   DTSBU521
00827 *****MOVE HOLD-PEN-SUB TO HOLD-ACCT-SUB.                          DTSBU521
00828 *****PERFORM P5000-NEGATIVE-BALANCE THRU P5000-EXIT.              DTSBU521
00829 *P4200-EXIT.                                                      DTSBU521
00830 *****EXIT.                                                        DTSBU521
00831      SKIP3                                                        DTSBU521
00832 *P4300-DECR-PEN-CHARGED.                                          DTSBU521
00833 *****COMPUTE WRK-PEN-CHARGED-AMT                                  DTSBU521
00834 *******= MQTR-CHARGED-AMT (HOLD-PEN-SUB) + L101-PEN-CHARGE-CHNG.  DTSBU521
00835                                                                   DTSBU521
00836 *****IF WRK-TAX-PAID-AMT NOT > +0                                 DTSBU521
00837 *********COMPUTE L541-AMT                                         DTSBU521
00838 ***********= MQTR-CHARGED-AMT (HOLD-PEN-SUB) * -1                 DTSBU521
00839 *****ELSE                                                         DTSBU521
00840 *****IF WRK-PEN-CHARGED-AMT < +0                                  DTSBU521
00841 *********COMPUTE L541-AMT                                         DTSBU521
00842 ***********= MQTR-CHARGED-AMT (HOLD-PEN-SUB) * -1                 DTSBU521
00843 *****ELSE                                                         DTSBU521
00844 *********MOVE L101-PEN-CHARGE-CHNG TO L541-AMT.                   DTSBU521
00845                                                                   DTSBU521
00846 *****MOVE HOLD-PEN-SUB TO L541-ACCT-SUB.                          DTSBU521
00847 *****MOVE CACT-CAT-CHARGED TO L541-CAT-IND.                       DTSBU521
00848 *****PERFORM S541-MODIFY-AMT THRU S541-EXIT.                      DTSBU521
00849                                                                   DTSBU521
00850 *****MOVE HOLD-PEN-SUB TO HOLD-ACCT-SUB.                          DTSBU521
00851 *****PERFORM P5000-NEGATIVE-BALANCE THRU P5000-EXIT.              DTSBU521
00852 *P4300-EXIT.                                                      DTSBU521
00853 *****EXIT.                                                        DTSBU521
00854      EJECT                                                        DTSBU521
00855  P5000-NEGATIVE-BALANCE.                                          DTSBU521
00856      IF MQTR-BALANCE-AMT (HOLD-ACCT-SUB) NOT < +0                 DTSBU521
00857          GO TO P5000-EXIT.                                        DTSBU521
00858                                                                   DTSBU521
00859      IF MQTR-PAID-AMT (HOLD-ACCT-SUB) > +0                        DTSBU521
00860          PERFORM P5100-DECR-PAID THRU P5100-EXIT.                 DTSBU521
00861                                                                   DTSBU521
00862      IF MQTR-BALANCE-AMT (HOLD-ACCT-SUB) NOT < +0                 DTSBU521
00863          GO TO P5000-EXIT.                                        DTSBU521
00864                                                                   DTSBU521
00865      IF MQTR-TOLER-AMT (HOLD-ACCT-SUB) > +0                       DTSBU521
00866          PERFORM P5300-DECR-TOLER THRU P5300-EXIT.                DTSBU521
00867                                                                   DTSBU521
00868      IF MQTR-BALANCE-AMT (HOLD-ACCT-SUB) NOT < +0                 DTSBU521
00869          GO TO P5000-EXIT.                                        DTSBU521
00870                                                                   DTSBU521
00871      IF MQTR-WAIVED-AMT (HOLD-ACCT-SUB) > +0                      DTSBU521
00872          PERFORM P5200-DECR-WAIVED THRU P5200-EXIT.               DTSBU521
00873                                                                   DTSBU521
00874      IF MQTR-BALANCE-AMT (HOLD-ACCT-SUB) < +0                     DTSBU521
00875          PERFORM S999-ABEND THRU S999-EXIT.                       DTSBU521
00876  P5000-EXIT.                                                      DTSBU521
00877      EXIT.                                                        DTSBU521
00878      SKIP3                                                        DTSBU521
00879  P5100-DECR-PAID.                                                 DTSBU521
00880      COMPUTE L522-AMT                                             DTSBU521
00881        = MQTR-PAID-AMT (HOLD-ACCT-SUB) * -1.                      DTSBU521
00882                                                                   DTSBU521
00883      IF L522-AMT < MQTR-BALANCE-AMT (HOLD-ACCT-SUB)               DTSBU521
00884          MOVE MQTR-BALANCE-AMT (HOLD-ACCT-SUB) TO L522-AMT.       DTSBU521
00885                                                                   DTSBU521
00886      COMPUTE L522-AMT = L522-AMT * -1.                            DTSBU521
00887                                                                   DTSBU521
00888      MOVE HOLD-ACCT-SUB TO L522-ACCT-SUB.                         DTSBU521
00889                                                                   DTSBU521
00890      PERFORM S522-REVERSE-PAID THRU S522-EXIT.                    DTSBU521
00891  P5100-EXIT.                                                      DTSBU521
00892      EXIT.                                                        DTSBU521
00893      SKIP3                                                        DTSBU521
00894  P5200-DECR-WAIVED.                                               DTSBU521
00895      COMPUTE L541-AMT                                             DTSBU521
00896        = MQTR-WAIVED-AMT (HOLD-ACCT-SUB) * -1.                    DTSBU521
00897                                                                   DTSBU521
00898      IF L541-AMT < MQTR-BALANCE-AMT (HOLD-ACCT-SUB)               DTSBU521
00899          MOVE MQTR-BALANCE-AMT (HOLD-ACCT-SUB) TO L541-AMT.       DTSBU521
00900                                                                   DTSBU521
00901      MOVE HOLD-ACCT-SUB TO L541-ACCT-SUB.                         DTSBU521
00902                                                                   DTSBU521
00903      MOVE CACT-CAT-WAIVED TO L541-CAT-IND.                        DTSBU521
00904                                                                   DTSBU521
00905      PERFORM S541-MODIFY-AMT THRU S541-EXIT.                      DTSBU521
00906                                                                   DTSBU521
00907                                                                   DTSBU521
00908      MOVE MQTR-YRQ TO L004-QTR-5-9.                               DTSBU521
00909                                                                   DTSBU521
00910      PERFORM S004-FROM-5 THRU S004-EXIT.                          DTSBU521
00911                                                                   DTSBU521
00912      IF HOLD-ACCT-SUB = HOLD-INT-SUB                              DTSBU521
00913          IF HOLD-YRQ-MSG5-SENT-88 (L004-ABS-QTR)                  DTSBU521
00914              NEXT SENTENCE                                        DTSBU521
00915          ELSE                                                     DTSBU521
00916              SET HOLD-YRQ-MSG5-SENT-88 (L004-ABS-QTR) TO TRUE     DTSBU521
00917              MOVE L004-SLASH-QTR TO MSG5-SLASHED-YRQ              DTSBU521
00918              MOVE MSG5-ID2 TO R907-MSG-ID                         DTSBU521
00919              MOVE MSG5-LONG-TEXT TO R907-MSG-TEXT                 DTSBU521
00920              PERFORM S946-R907-WRITE THRU S946-EXIT.              DTSBU521
00921 *****ELSE                                                         DTSBU521
00922 *********IF HOLD-YRQ-MSG6-SENT-88 (L004-ABS-QTR)                  DTSBU521
00923 *************NEXT SENTENCE                                        DTSBU521
00924 *********ELSE                                                     DTSBU521
00925 *************SET HOLD-YRQ-MSG6-SENT-88 (L004-ABS-QTR) TO TRUE     DTSBU521
00926 *************MOVE L004-SLASH-QTR TO MSG6-SLASHED-YRQ              DTSBU521
00927 *************MOVE MSG6-ID2 TO R907-MSG-ID                         DTSBU521
00928 *************MOVE MSG6-LONG-TEXT TO R907-MSG-TEXT                 DTSBU521
00929 *************PERFORM S946-R907-WRITE THRU S946-EXIT.              DTSBU521
00930  P5200-EXIT.                                                      DTSBU521
00931      EXIT.                                                        DTSBU521
00932      SKIP3                                                        DTSBU521
00933  P5300-DECR-TOLER.                                                DTSBU521
00934      COMPUTE L541-AMT                                             DTSBU521
00935        = MQTR-TOLER-AMT (HOLD-ACCT-SUB) * -1.                     DTSBU521
00936                                                                   DTSBU521
00937      IF L541-AMT < MQTR-BALANCE-AMT (HOLD-ACCT-SUB)               DTSBU521
00938          MOVE MQTR-BALANCE-AMT (HOLD-ACCT-SUB) TO L541-AMT.       DTSBU521
00939                                                                   DTSBU521
00940      MOVE HOLD-ACCT-SUB TO L541-ACCT-SUB.                         DTSBU521
00941                                                                   DTSBU521
00942      MOVE CACT-CAT-TOLER TO L541-CAT-IND.                         DTSBU521
00943                                                                   DTSBU521
00944      PERFORM S541-MODIFY-AMT THRU S541-EXIT.                      DTSBU521
00945  P5300-EXIT.                                                      DTSBU521
00946      EXIT.                                                        DTSBU521
00947      EJECT                                                        DTSBU521
00948  S1110-READ-MQTR.                                                 DTSBU521
00949      MOVE LOW-VALUES TO MQTR-KEY-AREA.                            DTSBU521
00950                                                                   DTSBU521
00951      MOVE MPRF-EMP-NO TO MQTR-EMP-NO.                             DTSBU521
00952                                                                   DTSBU521
00953      SET MQTR-QTR-88 TO TRUE.                                     DTSBU521
00954                                                                   DTSBU521
00955      MOVE L521-APPLIC-YRQ TO MQTR-YRQ.                            DTSBU521
00956                                                                   DTSBU521
00957      MOVE MQTR-KEY-AREA TO MSKL-KEY-AREA.                         DTSBU521
00958                                                                   DTSBU521
00959      PERFORM S910-READ THRU S910-EXIT.                            DTSBU521
00960                                                                   DTSBU521
00961      MOVE MSKL-REC TO MQTR-REC.                                   DTSBU521
00962  S1110-EXIT.                                                      DTSBU521
00963      EXIT.                                                        DTSBU521
00964      SKIP3                                                        DTSBU521
00965  S1120-REWRITE-MQTR.                                              DTSBU521
00966      MOVE +0 TO WRK-MQTR-TOT-BALANCE-AMT.                         DTSBU521
00967                                                                   DTSBU521
00968      PERFORM                                                      DTSBU521
00969        VARYING MQTR-ACCT-IDX FROM 1 BY 1                          DTSBU521
00970        UNTIL MQTR-ACCT-IDX > MQTR-ACCT-CNT                        DTSBU521
00971          ADD MQTR-BALANCE-AMT (MQTR-ACCT-IDX)                     DTSBU521
00972           TO WRK-MQTR-TOT-BALANCE-AMT                             DTSBU521
00973      END-PERFORM.                                                 DTSBU521
00974                                                                   DTSBU521
00975      IF (WRK-MQTR-TOT-BALANCE-AMT = +0)                           DTSBU521
00976           OR                                                      DTSBU521
00977         (WRK-MQTR-TOT-BALANCE-AMT > LBCM-QTR-TOL-MAX)             DTSBU521
00978          NEXT SENTENCE                                            DTSBU521
00979      ELSE                                                         DTSBU521
00980          PERFORM S590-QTR-TOL THRU S590-EXIT.                     DTSBU521
00981                                                                   DTSBU521
00982      MOVE MQTR-KEY-AREA TO MSKL-KEY-AREA.                         DTSBU521
00983                                                                   DTSBU521
00984      PERFORM S910-READ THRU S910-EXIT.                            DTSBU521
00985                                                                   DTSBU521
00986      IF L910-NO-REC-88                                            DTSBU521
00987          PERFORM S999-ABEND THRU S999-EXIT.                       DTSBU521
00988                                                                   DTSBU521
00989      MOVE MQTR-REC TO MSKL-REC.                                   DTSBU521
00990                                                                   DTSBU521
00991      PERFORM S910-REWRITE THRU S910-EXIT.                         DTSBU521
00992  S1120-EXIT.                                                      DTSBU521
00993      EXIT.                                                        DTSBU521
00994      SKIP3                                                        DTSBU521
00995  S2200-CRUNCH-ACCT-DATA.                                          DTSBU521
00996      MOVE 'N' TO ACCT-CRUNCH-COMPLETE-IND.                        DTSBU521
00997                                                                   DTSBU521
00998      MOVE +1 TO ACCT-SUB.                                         DTSBU521
00999                                                                   DTSBU521
01000      PERFORM S2210-CRUNCH-LOOP THRU S2210-EXIT                    DTSBU521
01001          UNTIL ACCT-CRUNCH-COMPLETE-IND = 'Y'.                    DTSBU521
01002  S2200-EXIT.                                                      DTSBU521
01003      EXIT.                                                        DTSBU521
01004      SKIP3                                                        DTSBU521
01005  S2210-CRUNCH-LOOP.                                               DTSBU521
01006      IF ACCT-SUB > MQTR-ACCT-CNT                                  DTSBU521
01007          MOVE 'Y' TO ACCT-CRUNCH-COMPLETE-IND                     DTSBU521
01008      ELSE                                                         DTSBU521
01009      IF (MQTR-CHARGED-AMT (ACCT-SUB) = 0)                         DTSBU521
01010               AND                                                 DTSBU521
01011         (MQTR-PAID-AMT    (ACCT-SUB) = 0)                         DTSBU521
01012               AND                                                 DTSBU521
01013         (MQTR-WAIVED-AMT  (ACCT-SUB) = 0)                         DTSBU521
01014               AND                                                 DTSBU521
01015         (MQTR-WRITTEN-OFF-AMT (ACCT-SUB) = 0)                     DTSBU521
01016               AND                                                 DTSBU521
01017         (MQTR-TOLER-AMT   (ACCT-SUB) = 0)                         DTSBU521
01018               AND                                                 DTSBU521
01019         (MQTR-BALANCE-AMT (ACCT-SUB) = 0)                         DTSBU521
01020          PERFORM S2211-SHUFFLE THRU S2211-EXIT                    DTSBU521
01021              VARYING ACCT-SUB1 FROM ACCT-SUB BY 1                 DTSBU521
01022              UNTIL ACCT-SUB1 NOT < MQTR-ACCT-CNT                  DTSBU521
01023          SUBTRACT 1 FROM MQTR-ACCT-CNT                            DTSBU521
01024      ELSE                                                         DTSBU521
01025          ADD +1 TO ACCT-SUB.                                      DTSBU521
01026  S2210-EXIT.                                                      DTSBU521
01027      EXIT.                                                        DTSBU521
01028      SKIP3                                                        DTSBU521
01029  S2211-SHUFFLE.                                                   DTSBU521
01030      COMPUTE ACCT-SUB2 = ACCT-SUB1 + 1.                           DTSBU521
01031                                                                   DTSBU521
01032      MOVE MQTR-ACCT-GROUP (ACCT-SUB2)                             DTSBU521
01033        TO MQTR-ACCT-GROUP (ACCT-SUB1).                            DTSBU521
01034  S2211-EXIT.                                                      DTSBU521
01035      EXIT.                                                        DTSBU521
01036      EJECT                                                        DTSBU521
01037  S004-FROM-5.                                                     DTSBU521
01038      SET L004-FROM-5 TO TRUE.                                     DTSBU521
01039      GO TO S004-QTR.                                              DTSBU521
01040                                                                   DTSBU521
01041  S004-QTR.                                                        DTSBU521
01042      CALL 'DTSBU004' USING L004-LINK-AREA.                        DTSBU521
01043                                                                   DTSBU521
01044      IF (L004-ABS-QTR < +1)                                       DTSBU521
01045            OR                                                     DTSBU521
01046         (L004-ABS-QTR > +400)                                     DTSBU521
01047          MOVE +1 TO L004-ABS-QTR.                                 DTSBU521
01048  S004-EXIT.                                                       DTSBU521
01049      EXIT.                                                        DTSBU521
01050      SKIP3                                                        DTSBU521
01051  S101-PER-MONTH-NO.                                               DTSBU521
01052      SET L101-PER-MONTH-NO-88 TO TRUE.                            DTSBU521
01053      GO TO S101-INT-CALC.                                         DTSBU521
01054                                                                   DTSBU521
01055  S101-INT-CALC.                                                   DTSBU521
01056      CALL 'DTSBU101' USING L101-LINK-AREA.                        DTSBU521
01057  S101-EXIT.                                                       DTSBU521
01058      EXIT.                                                        DTSBU521
01059  S109-FIRST-PEN-INT-YRQ.                                          DTSBU521
01060      SET L109-CMND-PEN-INT-QTR-88 TO TRUE.                        DTSBU521
01061      CALL 'DTSBU109' USING L109-LINK-AREA.                        DTSBU521
01062  S109-EXIT.                                                       DTSBU521
01063      EXIT.                                                        DTSBU521
01064                                                                   DTSBU521
01065  S522-REVERSE-PAID.                                               DTSBU521
01066      CALL 'DTSBU522' USING L522-LINK-AREA                         DTSBU521
01067                            LBCM-LINK-AREA                         DTSBU521
01068                            MPRF-REC                               DTSBU521
01069                            MQTR-REC.                              DTSBU521
01070  S522-EXIT.                                                       DTSBU521
01071      EXIT.                                                        DTSBU521
01072      SKIP3                                                        DTSBU521
01073  S541-MODIFY-AMT.                                                 DTSBU521
01074      MOVE LBCM-TRN-DOC-NO TO L541-TRN-DOC-NO.                     DTSBU521
01075                                                                   DTSBU521
01076      CALL 'DTSBU541' USING L541-LINK-AREA                         DTSBU521
01077                            MPRF-REC                               DTSBU521
01078                            MQTR-REC.                              DTSBU521
01079  S541-EXIT.                                                       DTSBU521
01080      EXIT.                                                        DTSBU521
01081      SKIP3                                                        DTSBU521
01082  S549-MJRN-TABLE.                                                 DTSBU521
01083      SET L549-DELTA-88 TO TRUE.                                   DTSBU521
01084                                                                   DTSBU521
01085      CALL 'DTSBU549' USING L549-LINK-AREA.                        DTSBU521
01086  S549-EXIT.                                                       DTSBU521
01087      EXIT.                                                        DTSBU521
01088      SKIP3                                                        DTSBU521
01089  S590-QTR-TOL.                                                    DTSBU521
01090      SET L590-QTR-TOL-88 TO TRUE.                                 DTSBU521
01091      MOVE MQTR-YRQ TO L590-YRQ.                                   DTSBU521
01092      MOVE WRK-NULL-DOC-NO TO L590-PAY-DOC-NO.                     DTSBU521
01093      GO TO S590-EMP-CLEANUP.                                      DTSBU521
01094                                                                   DTSBU521
01095  S590-EMP-CLEANUP.                                                DTSBU521
01096      MOVE LBCM-TRN-DOC-NO TO L590-TOL-DOC-NO.                     DTSBU521
01097                                                                   DTSBU521
01098      CALL 'DTSBU590' USING L590-LINK-AREA                         DTSBU521
01099                            LBCM-LINK-AREA                         DTSBU521
01100                            MPRF-REC.                              DTSBU521
01101  S590-EXIT.                                                       DTSBU521
01102      EXIT.                                                        DTSBU521
01103      SKIP3                                                        DTSBU521
01104  S910-READ.                                                       DTSBU521
01105      SET L910-READ-88 TO TRUE.                                    DTSBU521
01106      GO TO S910-MSTR-IO.                                          DTSBU521
01107                                                                   DTSBU521
01108 *S910-START-BROWSE.                                               DTSBU521
01109 *****SET L910-START-BROWSE-88 TO TRUE.                            DTSBU521
01110 *****GO TO S910-MSTR-IO.                                          DTSBU521
01111                                                                   DTSBU521
01112 *S910-READ-NEXT.                                                  DTSBU521
01113 *****SET L910-READ-NEXT-88 TO TRUE.                               DTSBU521
01114 *****GO TO S910-MSTR-IO.                                          DTSBU521
01115                                                                   DTSBU521
01116 *S910-COUNT.                                                      DTSBU521
01117 *****SET L910-COUNT-88 TO TRUE.                                   DTSBU521
01118 *****GO TO S910-MSTR-IO.                                          DTSBU521
01119                                                                   DTSBU521
01120 *S910-WRITE.                                                      DTSBU521
01121 *****SET LBCM-EMP-UPDATE-YES-88 TO TRUE.                          DTSBU521
01122 *****SET L910-WRITE-88 TO TRUE.                                   DTSBU521
01123 *****GO TO S910-MSTR-IO.                                          DTSBU521
01124                                                                   DTSBU521
01125  S910-REWRITE.                                                    DTSBU521
01126      SET LBCM-EMP-UPDATE-YES-88 TO TRUE.                          DTSBU521
01127      SET L910-REWRITE-88 TO TRUE.                                 DTSBU521
01128      GO TO S910-MSTR-IO.                                          DTSBU521
01129                                                                   DTSBU521
01130 *S910-DELETE.                                                     DTSBU521
01131 *****SET LBCM-EMP-UPDATE-YES-88 TO TRUE.                          DTSBU521
01132 *****SET L910-DELETE-88 TO TRUE.                                  DTSBU521
01133 *****GO TO S910-MSTR-IO.                                          DTSBU521
01134                                                                   DTSBU521
01135  S910-MSTR-IO.                                                    DTSBU521
01136      CALL 'DTSBU910' USING L910-LINK-AREA                         DTSBU521
01137                            MSKL-REC.                              DTSBU521
01138  S910-EXIT.                                                       DTSBU521
01139      EXIT.                                                        DTSBU521
01140      SKIP3                                                        DTSBU521
01141  S946-R907-WRITE.                                                 DTSBU521
01142      CALL 'DTSBU946' USING R907-REC.                              DTSBU521
01143  S946-EXIT.                                                       DTSBU521
01144      EXIT.                                                        DTSBU521
01145      SKIP3                                                        DTSBU521
01146  S999-ABEND.                                                      DTSBU521
01147      CALL 'DTSBU999' USING WRK-ABEND-CD.                          DTSBU521
01148  S999-EXIT.                                                       DTSBU521
01149      EXIT.                                                        DTSBU521
