Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Filter all the data within current month

Luca
8 - Asteroid

Hi All, 

 

I have a list of contracts in an excel file. 

 

I want to filter all the rows with "Start Date" up to the end of the current month. 

 

For example, the current month is April so I want to filter everything up to 30th Apr 2018.

 

Thanks,

Luca

4 REPLIES 4
LordNeilLord
15 - Aurora

Hey @Luca

 

Try this formula in the filter tool:

 

DateTimeFormat([Start Date], "%Y-%m") = DateTimeFormat(DateTimeToday(), "%Y-%m")

ThisMonth.PNG

Luca
8 - Asteroid

I have just tried to use [Service Start Date]<=DateTimeLastOfMonth() and it seems to do the job. 

 

Is there anything I could potentially miss using this formula?

LordNeilLord
15 - Aurora

Oh Sorry, I thought you wanted just Aprils data!

 

In which case your formula will be fine

 

@LordNeilLord

Part time Tableau, Part Time Alteryx. Full Time Awesome


Data Lover

dgoldrick
5 - Atom

If you wanted to keep it within the range of the current month you could add a conditional to the filter such as:

 

([Service Start Date] >= DateTimeFirstOfMonth()) AND ([Service Start Date] <= DateTimeLastOfMonth())

 

I get this was from around 4 years ago but if anybody sees this and needs it as a reference. Hope it helps! 

Labels