Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Dear colleagues,
I'm trying to create one formula in the script to get the true results for a series
I have in the database
Product | Comparison 1 | Comparison 2 | results |
a | 1 | 8 | 2 |
a | 2 | 2 | 2 |
a | 3 | 3 | 2 |
a | 4 | 4 | 2 |
I would like to have a formula where the results only show the true value in the series and don't consider the other.
Could anybody help me to define the formula?
Thanks in advance,
Leandro Duarte
I'm not completely clear on what you are trying to do, but I think you could try an if statement, leaving off the else part, then supress null values.
Hope I got what you want, I think I might have not really understood your issue (an example might help, then):
=if(Comparison1=Comparison2, results)
as expression?
If zero values are suppressed in presentation tab, you will only see rows with Comparison1 equals Comparison2 (if Product, Comparison1 and Comparison2 are dimension, with above expression)
Regards,
Stefan
How about an "IF" statement.
I dont know how yo get the number 2 in field results, but looks like if comparison 2 is >= comparison 1 Then results.
If is that case I think It would be something like this
If(Comparison 2 >= Comparison 1, 2,) as Results Flag
then you have created a new field with just numbers 2 and blank spaces, now you can use this field to make a new field
len(Results Flag) as ResultsFlag2
If(ResultsFlag2 =2, 2,Null()) as FinalResults Flag
this new field has just the registres with just the values with number 2.
I hope thats what you are looking for.