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

dinamic condition in dimention

Hi!

Please help if it possible.

I have expression:

=if(month = '201211',sum( TOTAL {<month={'201205'}>}Sale),0)

i need change month={'201205'} like this:

=if(month = '201211',sum( TOTAL {<month={month-6}>}Sale),0)

Is it possible to do someway?

1 Solution

Accepted Solutions
MayilVahanan

HI

PFA

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.

View solution in original post

7 Replies
Not applicable
Author

Hi,

You can use Addmonths() function as follows:

=if(month = '201211',sum( TOTAL {<month={AddMonths(month,-6)}>}Sale),0)

Not applicable
Author

Hi!

my "month" is not data field. it is string

Not applicable
Author

Hi!

Unfortunatly it does't work.

My field is a srting.

Please see attachment

Not applicable
Author

Hi,

Then convert string to date field using Date() and Date#() function, and use the expression stated above.

jonathan_dau
Contributor III
Contributor III

Hi,

Maybe you can use something like that :

sum( TOTAL {<month={">=$(=getfieldselections(month)-6)"}>}Sale)

Hope that helps

Jonathan

MayilVahanan

HI

PFA

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.
Not applicable
Author

Thank you vrey much!