I have a small idea for that but i don't know how to interpret it in sql server (MSDN).

```
if (Month < ActualMonth)
{
  (StartDateReq = FirstDayMonth);
  (EndDatereq) = LastDayMonth);
}
else if (Month = currenTimeStamp)
 {
  (EndDateReq = currentTimeStamp);
 }

```