Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Ilya_Bobrov
Contributor III
Contributor III

Partial Ignore of selections in filds using Set Analysis

Good day!
I got a problem with my expression.
When i select a month in the filter, i need to reflect data 
from the beginning of the year to the selected month inclusively.
I used 1 in my set analysis expression, but i need to keep the choice in the other filters(There are a lot of them)
not used in the expression. The expression itself: sum({1<[SalesYear]={$(=year(now()-2))},[MonthNum]={"<=$(=num(Month(Date#(GetFieldSelections([MonthName]),'MMMM'))))"}>}[Sales]) Thank you in advance!

 

Labels (3)
1 Solution

Accepted Solutions
Ilya_Bobrov
Contributor III
Contributor III
Author

I solved this problem by changing my expression and adding to it a variable containing a list of fields

Exspression:

sum({1<SalesYear={$(=year(now()-2)-1)},[MonthNum]={"<=$(=num(Month(Date#(GetFieldSelections([MonthName]),'MMMM'))))"},$(=concat({<$Field={$(=vFieldlist)}>} '[' & $Field & ']='&'$:: '&'['&$Field&']',','))>}[Sales])

View solution in original post

1 Reply
Ilya_Bobrov
Contributor III
Contributor III
Author

I solved this problem by changing my expression and adding to it a variable containing a list of fields

Exspression:

sum({1<SalesYear={$(=year(now()-2)-1)},[MonthNum]={"<=$(=num(Month(Date#(GetFieldSelections([MonthName]),'MMMM'))))"},$(=concat({<$Field={$(=vFieldlist)}>} '[' & $Field & ']='&'$:: '&'['&$Field&']',','))>}[Sales])