I wouldn't try it in this way else using appropriate information within a master-calendar, like defining a 1 for each calendar/working-day and then just applying sum(DayValue) or you may also calculate the max/kum days there and using max/avg() to pick them.
If i didn't have record on particular date then result is wrong. If May month has only records for 20 date. Then if I select May month it's show sum(dayvalue) is 20. But result I need to get is total days in month (i.e 31 days in May month)