Listing 5: Code That Finds the Target Date for the NHNM Example IF @B = 'H' AND @A ='N' BEGIN SET @current = (SELECT MIN(isodate) FROM @daytype WHERE dte > @holddate AND isHoliday = 1) END