Forum Discussion

ak77's avatar
ak77
Post Patron
3 years ago

Sign change

Hi All,

 

i need a help.. i have the below table where i have a measure QTD_MS_Change doing a calculation. i need to change the sign (+ if -) and (- to +)  for all the rows which has Benchmark in Asset/SubClass benchmark Columns

 

For Ex: 1.48 to -1.48 , 3.44 to -3.44, -4.54 to 4.54 and so on.  is there a way to achive this. Please help

 

 

 

7 Replies

  • ak77's avatar
    ak77
    Post Patron

    parry2k , Thanks for reply...tried that..but it is changing sign for all the values. i need it only for rows which has benchmark. if i try to use a new measure to put a condition.. i am not able to use measure within measure

  • ak77 wrap it with IF condition:

     

    New Measure = 
    IF ( CONTAINSSTRING ( SELECTEDVALUE ( YourTable[YourColumn] ), "Benchmark" ), -1, 1 ) 
    * [Your Measure] 
  • ak77's avatar
    ak77
    Post Patron
    New Measure = 
    IF ( CONTAINSSTRING ( SELECTEDVALUE ( YourTable[YourColumn] ), "Benchmark" ), -1, 1 ) 
    * [Your Measure] 
    parry2k , Thanks .  My question is how can i use [Your Measure] in [New measure] in the above expression..
     
    when i try creating [New measure] and try to access [Your Measure] to use it in the formula.. it does not show up 😞