Google
 

Trailing-Edge - PDP-10 Archives - decuslib10-12 - 43,50553/fndnew.for
There are no other files named fndnew.for in the archive.
      SUBROUTINE FNDNEW(NOWMTH,NOWYER,MCHMTH,MCHYER,IERASE)
C     RENBR(/TESTS IF MONTHLY TAPE STILL EXISTS)
C
C     DONALD BARTH, HARVARD BUSINESS SCHOOL
C
C     THIS ROUTINE DEPENDS UPON THE RECYCLING SCHEDULE FOR
C     THE MONTHLY SAVE TAPES OF THE PUBLIC DISK STRUCTURES.
C     THE LOGIC IN THIS ROUTINE CAN BE DELETED IF ALL TAPE
C     SETS ARE STILL AVAILABLE.   IT WOULD THEN JUST
C     CONSIST OF THE SUBROUTINE, RETURN AND END STATEMENTS.
C
C     FOLLOWING ARGUMENTS ARE RETURNED UNCHANGED
C     NOWMTH = CURRENT MONTH, 1 = JANUARY
C     NOWYER = CURRENT YEAR, RIGHT 2 DIGITS
C     MCHMTH = MONTH OF DATE TO BE SEARCHED, 1 = JANUARY
C     MCHYER = YEAR OF DATE TO BE SEARCHED, RIGHT 2 DIGITS
C
C     NOTE THAT AFTER YEAR AT YEAR 2000, NOWYER AND MCHYER
C     BECOME RIGHT 2 DIGITS PLUS 100.
C
C     FOLLOWING ARGUMENT IS RETURNED CHANGED
C     ITS INPUT VALUE IS IGNORED, BUT SHOULD BE 0
C     IERASE = 0, THE TAPE STILL EXISTS
C            = 1, THE TAPE HAS BEEN ERASED
C
C     THIS ROUTINE CHECKS WHETHER A PARTICULAR MONTHLY
C     BACKUP TAPE STILL EXISTS.  IF ALL TAPES ARE KEPT
C     FOREVER, THEN THIS ROUTINE CAN BE REPLACED BY A
C     DUMMY ROUTINE WHICH DOES NOTHING.  THIS VERSION
C     SUPPORTS THE FOLLOWING RECYCLING SCHEDULE.
C
C      JANUARY TAPES ARE KEPT  3 YEARS
C     FEBRUARY TAPES ARE KEPT  4 YEARS
C        MARCH TAPES ARE KEPT  5 YEARS
C        APRIL TAPES ARE KEPT  3 YEARS
C          MAY TAPES ARE KEPT  4 YEARS
C         JUNE TAPES ARE KEPT 10 YEARS
C         JULY TAPES ARE KEPT  3 YEARS
C       AUGUST TAPES ARE KEPT  4 YEARS
C    SEPTEMBER TAPES ARE KEPT  5 YEARS
C      OCTOBER TAPES ARE KEPT  3 YEARS
C     NOVEMBER TAPES ARE KEPT  4 YEARS
C     DECEMBER TAPES ARE KEPT 10 YEARS
C
C     NUMBER OF YEARS EACH MONTHLY TAPE IS KEPT
      DIMENSION KEPYER(12)
      DATA KEPYER/3,4,5,3,4,10,3,4,5,3,4,10/
C
C     CALCULATE AGE OF THE TAPE
      IAGE=NOWYER-MCHYER
      IF(MCHMTH.GE.NOWMTH)IAGE=IAGE-1
      IERASE=0
      IF(IAGE.GE.KEPYER(MCHMTH))IERASE=1
      RETURN
      END