Dieter,
Yes thats correct. It worked very well for me.
But tweaked to get my final result as expected.
BETWEEN
CASE
WHEN EXTRACT(DAY FROM CURRENT_DATE) >= 7 THEN (CURRENT_DATE - extract(day from CURRENT_DATE)+1)
ELSE
ADD_MONTHS(CURRENT_DATE - (EXTRACT(DAY FROM CURRENT_DATE)-1), -1)
END
AND CURRENT_DATE
Thanks a lot.
_Mallesh
↧