Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I am struggling with obtaining the Min and Max Dates for
expression labels. I have 2 alternate states created and I want the label to
dynamically show the min and max dates for the user section. S that If 1 state
was Oct Through May, it would show Oct … May.
I normally use the following when it’s not an alternate
state
Month(min(DATE_SORT))&' ...
'&Month(max(DATE_SORT))
Any ideas?
Hi james,
Set Expression will be a bit different while using Alternate States.
in your case, the expression would likely be
month(min({StateA <[Date]=[StateB]::Date>} if(Date >= '5/1/2005' and Date <= '10/31/2005', Date) )) & '...' &
month(max({StateB <[Date]=[StateA]::Date>} if(Date >= '5/1/2005' and Date <= '10/31/2005', Date)))
--> you can remove the IF() conditions and put your own field
May be like this:
Month(min({NameofAlternateState}DATE_SORT))&' ...
'&Month(max({NameofAlternateState}DATE_SORT))
Yes, that doesn’t work. I have tried that
What exactly are your trying to do? May be I don't completely understand your requirement.
I have 2 alternate states With Period as a section.
I want the Label to Show the Min Period and the max period, so that I don’t see 7 period names in the label. I’d rather see Oct…Mar, which I can always do when I’m not dealing with Alternate States
Hi james,
Set Expression will be a bit different while using Alternate States.
in your case, the expression would likely be
month(min({StateA <[Date]=[StateB]::Date>} if(Date >= '5/1/2005' and Date <= '10/31/2005', Date) )) & '...' &
month(max({StateB <[Date]=[StateA]::Date>} if(Date >= '5/1/2005' and Date <= '10/31/2005', Date)))
--> you can remove the IF() conditions and put your own field
Thanks that works, I just now need to make the if(Date >= a variable off of the alternate state
This works fine… I guess the if section is just a fake statement to help it render
=Only( Year) &chr(10)& month(min({State1 <[PER]=[State1]::PER>} if(DATE_SORT >= vMaxDate, DATE_SORT) )) &'...'& month(max({State1 <[PER]=[State1]::PER>} if(DATE_SORT >= vMaxDate, DATE_SORT) )) &chr(10)& Only( PlanVersion)
Awesome..Hope i helped you. happy Qliking.
Thanks
krishna
Please mark it answered.
Thanks