Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Pick up dates less than or equal to selection

Hi guys,

I'm trying to create a measure "Max Date" that will base my selection from my filter for month and day.  When I make a selection Month=Feb and Day=2. I want to be able to show all dates less than or equal to the date I have selected.

So basically dates from Jan 1 to Feb 2.... Below is my code for my chart expression. Appreciate any guidance/help.

Cheers-sv

If(Year(max([MaxDate]))<=YearDate

and Month(max([MaxDate]))<=MonthDate

and Day(max([MaxDate]))<=DayDate, date([MaxDate]),

date(max([MaxDate])))

6 Replies
sunny_talwar

May be check this out:

Selecting Arbitrary Date Ranges

Anonymous
Not applicable
Author

jagan
Luminary Alumni
Luminary Alumni

Hi,

Check this link for sample

Implementing From and To Date Selection using Calendar Objects

Regards,

Jagan.

mohammadkhatimi
Partner - Specialist
Partner - Specialist

Variables:-

vStartDate=Date(YearStart(MinString(DATE)))

vEnd==Date((MaxString(Date)))

Add this in expression:-

Date={">=$(vStart)<=$(vEnd)"}

Hope this will hepls u..!!

Regards,

Mohammad

teiswamsler
Partner - Creator III
Partner - Creator III

Hi Sean

Here is a comprehensive guide to understanding date use in Set Analysis by hic

Dates in Set Analysis

/Teis

Not applicable
Author

Thanks guys for the helpful response