00001  IDENTIFICATION DIVISION.                                         04/05/04
00002  PROGRAM-ID.             DTSBU982.                                DTSBU982
00003  AUTHOR.                 TRW.                                        LV003
00004  DATE-WRITTEN.           FEBRUARY 2002.                           DTSBU982
00005  DATE-COMPILED.                                                   DTSBU982
00006      SKIP3                                                        DTSBU982
00007 *****                                                             DTSBU982
00008 *                                                                 DTSBU982
00009 *    FUNCTION:  NAME FILE INPUT/OUTPUT.                           DTSBU982
00010 *                                                                 DTSBU982
00011 *                                                                 DTSBU982
00012 *    MODIFICATION LOG:                                            DTSBU982
00013 *                                                                 DTSBU982
00014 *    09/02/2003  INITIAL DEVELOPMENT.                             DTSBU982
00015 *                WORK ORDER:                      PROGRAMMER: GD  DTSBU982
00016 *                                                                 DTSBU982
00017 *    MM/DD/YYYY  XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX   DTSBU982
00018 *                XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX   DTSBU982
00019 *                REFERENCE: XXXXXXXXXXXXXXX     PROGRAMMER: XXX   DTSBU982
00020 *                                                                 DTSBU982
00021 *                                                                 DTSBU982
00022 *    DESCRIPTION:                                                 DTSBU982
00023 *                                                                 DTSBU982
00024 *        DTSBU982 PERFORMS ALL REQUIRED NAME FILE                 DTSBU982
00025 *        INPUT/OUTPUT.                                            DTSBU982
00026 *                                                                 DTSBU982
00027 *        NAME RECORDS ARE STORED UNDER SSN AND NINES-COMPLEMENT   DTSBU982
00028 *        ABSOLUTE TIME, WHICH ALLOWS FOR A HISTORY OF NAMES       DTSBU982
00029 *        FOR EACH SSN WITH THE MOST RECENT FIRST.                 DTSBU982
00030 *                                                                 DTSBU982
00031 *        TO RETRIEVE THE CURRENT NAME, PERFORM A START BROWSE     DTSBU982
00032 *        USING THE SSN, WITH ZERO IN THE ABSTIME FIELD.           DTSBU982
00033 *                                                                 DTSBU982
00034 *        WNAM-NAME-TYPE INDICATES THE SOURCE OF THE NAME.         DTSBU982
00035 *           WNAM-TYPE-W4-88 - ORIGINAL WAGE FILE - 3 CHARACTERS   DTSBU982
00036 *           WNAM-TYPE-WEB-88 - FROM WEB APPLICATION - FULL NAME   DTSBU982
00037 *                                                                 DTSBU982
00038 *                                                                 DTSBU982
00039 *    GENERAL SPECIFICATIONS:                                      DTSBU982
00040 *                                                                 DTSBU982
00041 *        ALL COMMANDS ARE VALID.                                  DTSBU982
00042 *                                                                 DTSBU982
00043 *        IF AN INVALID COMMAND IS REQUESTED, THEN ABEND THE       DTSBU982
00044 *        MODULE.                                                  DTSBU982
00045 *                                                                 DTSBU982
00046 *        IF A FILE-STATUS OF OTHER THAN '00', '10', OR '23' IS    DTSBU982
00047 *        ENCOUNTERED, THEN ABEND PROCESSING (TOLERATE A           DTSBU982
00048 *        FILE-STATUS OF '97' FROM AN OPEN COMMAND).               DTSBU982
00049 *                                                                 DTSBU982
00050 *                                                                 DTSBU982
00051 *                                                                 DTSBU982
00052 *    COMMAND SPECIFIC SPECIFICATIONS:                             DTSBU982
00053 *                                                                 DTSBU982
00054 *    OPEN-READ                                                    DTSBU982
00055 *        OPEN INPUT.                                              DTSBU982
00056 *                                                                 DTSBU982
00057 *    OPEN-UPDATE                                                  DTSBU982
00058 *        OPEN I-O.                                                DTSBU982
00059 *                                                                 DTSBU982
00060 *    CLOSE                                                        DTSBU982
00061 *                                                                 DTSBU982
00062 *    READ                                                         DTSBU982
00063 *                                                                 DTSBU982
00064 *    START BROWSE                                                 DTSBU982
00065 *        IF THE START-BROWSE IS SUCCESSFUL, THEN PERFORM THE      DTSBU982
00066 *        READ-NEXT LOGIC.  A SUCCESSFUL START-BROWSE RETURNS      DTSBU982
00067 *        A RECORD.                                                DTSBU982
00068 *                                                                 DTSBU982
00069 *    READ NEXT                                                    DTSBU982
00070 *                                                                 DTSBU982
00071 *    WRITE                                                        DTSBU982
00072 *                                                                 DTSBU982
00073 *    REWRITE                                                      DTSBU982
00074 *                                                                 DTSBU982
00075 *    DELETE                                                       DTSBU982
00076 *                                                                 DTSBU982
00077 *                                                                 DTSBU982
00078 *****                                                             DTSBU982
00079      SKIP3                                                        DTSBU982
00080  ENVIRONMENT DIVISION.                                            DTSBU982
00081      SKIP2                                                        DTSBU982
00082  INPUT-OUTPUT SECTION.                                            DTSBU982
00083                                                                   DTSBU982
00084  FILE-CONTROL.                                                    DTSBU982
00085      SELECT NAME-FILE ASSIGN TO DTSFNAME                          DTSBU982
00086          ORGANIZATION IS INDEXED                                  DTSBU982
00087          RECORD KEY IS WNAM-KEY-AREA OF FILE-REC                  DTSBU982
00088          FILE STATUS IS FILE-STATUS                               DTSBU982
00089          ACCESS IS DYNAMIC.                                       DTSBU982
00090      SKIP3                                                        DTSBU982
00091  DATA DIVISION.                                                   DTSBU982
00092      SKIP3                                                        DTSBU982
00093  FILE SECTION.                                                    DTSBU982
00094      SKIP3                                                        DTSBU982
00095  FD  NAME-FILE.                                                   DTSBU982
00096                                                                   DTSBU982
00097  01  FILE-REC.                                                    DTSBU982
00098  ++INCLUDE DTSIWNAM                                               DTSBU982
00099      EJECT                                                        DTSBU982
00100  WORKING-STORAGE SECTION.                                         DTSBU982
001005 77  PAN-VALET PICTURE X(24) VALUE '003DTSBU982  04/05/04'.       DTSBU982
00101      SKIP3                                                        DTSBU982
00102  01  WRK-AREA.                                                    DTSBU982
00103      05  WRK-ABEND-CD                PIC S9(04)  COMP  VALUE +982.DTSBU982
00104                                                                   DTSBU982
00105      05  WRK-MOD-NAME                PIC  X(08)  VALUE 'DTSBU982'.DTSBU982
00106                                                                   DTSBU982
00107      05  WRK-REC-PREFIX              PIC  X(04).                  DTSBU982
00108                                                                   DTSBU982
00109      05  WRK-KEY-LENGTH              PIC S9(04)  COMP             DTSBU982
00110                                          VALUE +13.               DTSBU982
00111                                                                   DTSBU982
00112      05  FILE-STATUS                 PIC  X(02).                  DTSBU982
00113          88  FILE-OK-88                  VALUE '00'.              DTSBU982
00114          88  FILE-NO-REC-88              VALUE '10' '23'.         DTSBU982
00115          88  FILE-VERIFY-88              VALUE '97'.              DTSBU982
00116          88  FILE-DUP-88                 VALUE '22'.              DTSBU982
00117      EJECT                                                        DTSBU982
00118  01  L991-LINK-AREA.                                              DTSBU982
00119  ++INCLUDE DTSIL991                                               DTSBU982
00120      EJECT                                                        DTSBU982
00121  LINKAGE SECTION.                                                 DTSBU982
00122      SKIP3                                                        DTSBU982
00123  01  L982-LINK-AREA.                                              DTSBU982
00124  ++INCLUDE DTSIL982                                               DTSBU982
00125      EJECT                                                        DTSBU982
00126  01  LINK-REC.                                                    DTSBU982
00127      05  WNAM-REC.                                                DTSBU982
00128  ++INCLUDE DTSIWNAM                                               DTSBU982
00129      EJECT                                                        DTSBU982
00130  PROCEDURE DIVISION USING L982-LINK-AREA                          DTSBU982
00131                           LINK-REC.                               DTSBU982
00132                                                                   DTSBU982
00133      SET L982-OK-88 TO TRUE.                                      DTSBU982
00134                                                                   DTSBU982
00135      IF L982-TRACE-88                                             DTSBU982
00136          PERFORM S9100-PRE-DISPLAY THRU S9100-EXIT.               DTSBU982
00137                                                                   DTSBU982
00138      IF L982-READ-NEXT-88                                         DTSBU982
00139          PERFORM P2300-READ-NEXT THRU P2300-EXIT                  DTSBU982
00140      ELSE                                                         DTSBU982
00141      IF L982-READ-88                                              DTSBU982
00142          PERFORM P2100-READ THRU P2100-EXIT                       DTSBU982
00143      ELSE                                                         DTSBU982
00144      IF L982-START-BROWSE-88                                      DTSBU982
00145          PERFORM P2200-START-BROWSE THRU P2200-EXIT               DTSBU982
00146      ELSE                                                         DTSBU982
00147      IF L982-WRITE-88                                             DTSBU982
00148          PERFORM P3100-WRITE THRU P3100-EXIT                      DTSBU982
00149      ELSE                                                         DTSBU982
00150      IF L982-REWRITE-88                                           DTSBU982
00151          PERFORM P3200-REWRITE THRU P3200-EXIT                    DTSBU982
00152      ELSE                                                         DTSBU982
00153      IF L982-DELETE-88                                            DTSBU982
00154          PERFORM P3300-DELETE THRU P3300-EXIT                     DTSBU982
00155      ELSE                                                         DTSBU982
00156      IF L982-OPEN-READ-88                                         DTSBU982
00157            OR                                                     DTSBU982
00158         L982-OPEN-UPDATE-88                                       DTSBU982
00159          PERFORM P1100-OPEN THRU P1100-EXIT                       DTSBU982
00160      ELSE                                                         DTSBU982
00161      IF L982-CLOSE-88                                             DTSBU982
00162          PERFORM P1200-CLOSE THRU P1200-EXIT                      DTSBU982
00163      ELSE                                                         DTSBU982
00164          PERFORM S999-ABEND THRU S999-EXIT.                       DTSBU982
00165                                                                   DTSBU982
00166      IF L982-TRACE-88                                             DTSBU982
00167          PERFORM S9200-POST-DISPLAY THRU S9200-EXIT.              DTSBU982
00168      SKIP2                                                        DTSBU982
00169      GOBACK.                                                      DTSBU982
00170      EJECT                                                        DTSBU982
00171  P1100-OPEN.                                                      DTSBU982
00172      IF L982-OPEN-UPDATE-88                                       DTSBU982
00173          OPEN I-O NAME-FILE                                       DTSBU982
00174      ELSE                                                         DTSBU982
00175          OPEN INPUT NAME-FILE.                                    DTSBU982
00176                                                                   DTSBU982
00177      IF FILE-OK-88 OR FILE-VERIFY-88                              DTSBU982
00178          NEXT SENTENCE                                            DTSBU982
00179      ELSE                                                         DTSBU982
00180          PERFORM S999-ABEND THRU S999-EXIT.                       DTSBU982
00181  P1100-EXIT.                                                      DTSBU982
00182      EXIT.                                                        DTSBU982
00183      SKIP3                                                        DTSBU982
00184  P1200-CLOSE.                                                     DTSBU982
00185      CLOSE NAME-FILE.                                             DTSBU982
00186                                                                   DTSBU982
00187      IF FILE-OK-88                                                DTSBU982
00188          NEXT SENTENCE                                            DTSBU982
00189      ELSE                                                         DTSBU982
00190          PERFORM S999-ABEND THRU S999-EXIT.                       DTSBU982
00191  P1200-EXIT.                                                      DTSBU982
00192      EXIT.                                                        DTSBU982
00193      EJECT                                                        DTSBU982
00194  P2100-READ.                                                      DTSBU982
00195      MOVE WNAM-KEY-AREA OF LINK-REC                               DTSBU982
00196        TO WNAM-KEY-AREA OF FILE-REC.                              DTSBU982
00197                                                                   DTSBU982
00198      READ NAME-FILE.                                              DTSBU982
00199                                                                   DTSBU982
00200      IF FILE-OK-88                                                DTSBU982
00201          MOVE FILE-REC  TO LINK-REC                               DTSBU982
00202      ELSE                                                         DTSBU982
00203      IF FILE-NO-REC-88                                            DTSBU982
00204          PERFORM S1100-NO-REC THRU S1100-EXIT                     DTSBU982
00205      ELSE                                                         DTSBU982
00206          PERFORM S999-ABEND THRU S999-EXIT.                       DTSBU982
00207  P2100-EXIT.                                                      DTSBU982
00208      EXIT.                                                        DTSBU982
00209      EJECT                                                        DTSBU982
00210  P2200-START-BROWSE.                                              DTSBU982
00211      MOVE WNAM-KEY-AREA OF LINK-REC                               DTSBU982
00212        TO WNAM-KEY-AREA OF FILE-REC.                              DTSBU982
00213                                                                   DTSBU982
00214      START NAME-FILE                                              DTSBU982
00215          KEY IS NOT < WNAM-KEY-AREA OF FILE-REC.                  DTSBU982
00216                                                                   DTSBU982
00217      IF FILE-OK-88                                                DTSBU982
00218          PERFORM P2300-READ-NEXT THRU P2300-EXIT                  DTSBU982
00219      ELSE                                                         DTSBU982
00220      IF FILE-NO-REC-88                                            DTSBU982
00221          PERFORM S1100-NO-REC THRU S1100-EXIT                     DTSBU982
00222      ELSE                                                         DTSBU982
00223          PERFORM S999-ABEND THRU S999-EXIT.                       DTSBU982
00224  P2200-EXIT.                                                      DTSBU982
00225      EXIT.                                                        DTSBU982
00226      EJECT                                                        DTSBU982
00227  P2300-READ-NEXT.                                                 DTSBU982
00228      READ NAME-FILE NEXT.                                         DTSBU982
00229                                                                   DTSBU982
00230      IF FILE-OK-88                                                DTSBU982
00231          MOVE FILE-REC  TO LINK-REC                               DTSBU982
00232      ELSE                                                         DTSBU982
00233      IF FILE-NO-REC-88                                            DTSBU982
00234          PERFORM S1100-NO-REC THRU S1100-EXIT                     DTSBU982
00235      ELSE                                                         DTSBU982
00236          PERFORM S999-ABEND THRU S999-EXIT.                       DTSBU982
00237  P2300-EXIT.                                                      DTSBU982
00238      EXIT.                                                        DTSBU982
00239      EJECT                                                        DTSBU982
00240  P3100-WRITE.                                                     DTSBU982
00241      MOVE LINK-REC  TO FILE-REC.                                  DTSBU982
00242                                                                   DTSBU982
00243      WRITE FILE-REC.                                              DTSBU982
00244                                                                   DTSBU982
00245      IF FILE-OK-88                                                DTSBU982
00246          NEXT SENTENCE                                            DTSBU982
00247      ELSE                                                         DTSBU982
00248         IF FILE-DUP-88                                            DTSBU982
00249            DISPLAY 'BU982 DUP ' WNAM-SSN OF LINK-REC              DTSBU982
00250               '  ' WNAM-LAST-NAME OF LINK-REC                     DTSBU982
00251         ELSE                                                      DTSBU982
00252            PERFORM S999-ABEND THRU S999-EXIT.                     DTSBU982
00253  P3100-EXIT.                                                      DTSBU982
00254      EXIT.                                                        DTSBU982
00255      EJECT                                                        DTSBU982
00256  P3200-REWRITE.                                                   DTSBU982
00257      MOVE LINK-REC  TO FILE-REC.                                  DTSBU982
00258                                                                   DTSBU982
00259      REWRITE FILE-REC.                                            DTSBU982
00260                                                                   DTSBU982
00261      IF FILE-OK-88                                                DTSBU982
00262          NEXT SENTENCE                                            DTSBU982
00263      ELSE                                                         DTSBU982
00264         IF FILE-DUP-88                                            DTSBU982
00265            DISPLAY 'BU982 DUP ' WNAM-SSN OF LINK-REC              DTSBU982
00266               '  ' WNAM-LAST-NAME OF LINK-REC                     DTSBU982
00267         ELSE                                                      DTSBU982
00268          PERFORM S999-ABEND THRU S999-EXIT.                       DTSBU982
00269  P3200-EXIT.                                                      DTSBU982
00270      EXIT.                                                        DTSBU982
00271      EJECT                                                        DTSBU982
00272  P3300-DELETE.                                                    DTSBU982
00273      MOVE WNAM-KEY-AREA OF LINK-REC                               DTSBU982
00274        TO WNAM-KEY-AREA OF FILE-REC.                              DTSBU982
00275                                                                   DTSBU982
00276      DELETE NAME-FILE RECORD.                                     DTSBU982
00277                                                                   DTSBU982
00278      IF FILE-OK-88                                                DTSBU982
00279          NEXT SENTENCE                                            DTSBU982
00280      ELSE                                                         DTSBU982
00281          PERFORM S999-ABEND THRU S999-EXIT.                       DTSBU982
00282  P3300-EXIT.                                                      DTSBU982
00283      EXIT.                                                        DTSBU982
00284      EJECT                                                        DTSBU982
00285  S1100-NO-REC.                                                    DTSBU982
00286      SET L982-NO-REC-88 TO TRUE.                                  DTSBU982
00287  S1100-EXIT.                                                      DTSBU982
00288      EXIT.                                                        DTSBU982
00289      SKIP3                                                        DTSBU982
00290  S9100-PRE-DISPLAY.                                               DTSBU982
00291      DISPLAY ' '.                                                 DTSBU982
00292                                                                   DTSBU982
00293      DISPLAY ' '.                                                 DTSBU982
00294                                                                   DTSBU982
00295      DISPLAY '*** DTSBU982 PRE  TRACE DISPLAY ***'.               DTSBU982
00296                                                                   DTSBU982
00297      DISPLAY L982-MOD-NAME                                        DTSBU982
00298              ' = L982-MOD-NAME'.                                  DTSBU982
00299                                                                   DTSBU982
00300      DISPLAY L982-CMND-CD                                         DTSBU982
00301              ' = L982-CMND-CD'.                                   DTSBU982
00302                                                                   DTSBU982
00303      PERFORM S9300-REC-DISPLAY THRU S9300-EXIT.                   DTSBU982
00304  S9100-EXIT.                                                      DTSBU982
00305      EXIT.                                                        DTSBU982
00306      SKIP3                                                        DTSBU982
00307  S9200-POST-DISPLAY.                                              DTSBU982
00308      DISPLAY ' '.                                                 DTSBU982
00309                                                                   DTSBU982
00310      DISPLAY ' '.                                                 DTSBU982
00311                                                                   DTSBU982
00312      DISPLAY '*** DTSBU982 POST TRACE DISPLAY ***'.               DTSBU982
00313                                                                   DTSBU982
00314      DISPLAY L982-RESULT-IND                                      DTSBU982
00315              ' = L982-RESULT-IND'.                                DTSBU982
00316                                                                   DTSBU982
00317      PERFORM S9300-REC-DISPLAY THRU S9300-EXIT.                   DTSBU982
00318  S9200-EXIT.                                                      DTSBU982
00319      EXIT.                                                        DTSBU982
00320      SKIP3                                                        DTSBU982
00321  S9300-REC-DISPLAY.                                               DTSBU982
00322      DISPLAY ' '.                                                 DTSBU982
00323                                                                   DTSBU982
00324      MOVE 'WNAM'  TO WRK-REC-PREFIX.                              DTSBU982
00325      MOVE WRK-KEY-LENGTH TO L991-REQ-CHAR-CNT.                    DTSBU982
00326                                                                   DTSBU982
00327      MOVE WNAM-KEY-AREA OF LINK-REC TO L991-REQ-AREA.             DTSBU982
00328                                                                   DTSBU982
00329      PERFORM S991-HEX-FORMAT THRU S991-EXIT.                      DTSBU982
00330                                                                   DTSBU982
00331      DISPLAY 'REC TYPE = '                                        DTSBU982
00332              WRK-REC-PREFIX.                                      DTSBU982
00333                                                                   DTSBU982
00334      DISPLAY 'KEY AREA = '                                        DTSBU982
00335              L991-REPLY-HEX-1-AREA.                               DTSBU982
00336                                                                   DTSBU982
00337      DISPLAY '           '                                        DTSBU982
00338              L991-REPLY-HEX-2-AREA.                               DTSBU982
00339                                                                   DTSBU982
00340      DISPLAY '           '                                        DTSBU982
00341              L991-REPLY-AN-AREA.                                  DTSBU982
00342  S9300-EXIT.                                                      DTSBU982
00343      EXIT.                                                        DTSBU982
00344      EJECT                                                        DTSBU982
00345  S991-HEX-FORMAT.                                                 DTSBU982
00346      CALL 'DTSBU991' USING L991-LINK-AREA.                        DTSBU982
00347  S991-EXIT.                                                       DTSBU982
00348      EXIT.                                                        DTSBU982
00349      EJECT                                                        DTSBU982
00350  S999-ABEND.                                                      DTSBU982
00351      DISPLAY '*** DTSBU982 I/O MODULE ABENDING'.                  DTSBU982
00352                                                                   DTSBU982
00353      DISPLAY '*** CMND-CD = ' L982-CMND-CD.                       DTSBU982
00354                                                                   DTSBU982
00355      DISPLAY '*** FILE-STATUS = ' FILE-STATUS.                    DTSBU982
00356                                                                   DTSBU982
00357      DISPLAY '*** CALLING MODULE = ' L982-MOD-NAME.               DTSBU982
00358                                                                   DTSBU982
00359      PERFORM S9300-REC-DISPLAY THRU S9300-EXIT.                   DTSBU982
00360                                                                   DTSBU982
00361      CALL 'DTSBU999' USING WRK-ABEND-CD.                          DTSBU982
00362  S999-EXIT.                                                       DTSBU982
00363      EXIT.                                                        DTSBU982
