Babloo

Babloo

  • NA
  • 92
  • 21.2k

how to get last 8 month from 2019 and first 3 month from fin

May 20 2019 7:35 AM
select top 1 sum((NoofDayPresent+ELtaken+CLTaken+Holiday +PaidLeave)) from AttendenceMonthWise where EmployeeID=2 and MonthID in(4,5,6,7,8,9,10,11,12) and YearID=2019
and MonthID in (select MonthID=1,2,3 from AttendenceMonthWise where YearID=2020)

Answers (2)