Start of the Month and End of the month

Do we have any inbuilt formula to get last day of the month and start of the month in quicksight. In case no then is there any formula that we can use to get these values

hi @Kushal_Garg,

thank you for posting your inquiry!

you can use truncDate() with “MM” (month) which returns the first day of the month. so if you want to know the 1st day of the month from today, it will be

truncDate(“MM”, now())

for the last day of the month, you can use addDateTime() which adds or subtracts time from datetime value, with the combination of the above truncDate(). so for the last day of the month from today will be

addDateTime(-1, ‘DD’, addDateTime(1, ‘MM’, truncDate(“MM”, now())))

regards,
Wakana

Hi,

Thanks a lot, really appreciate the quick response.