Hi @Davidson Espindola 
First date of every month will be 1 which you can concat with current month and year however for last month you can use LAST_DAY cache function by passing any date of desire month.
SELECT LAST_DAY('2004-02-25')  

For details check below documentations:

https://docs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY...

https://docs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY...

Thanks