Forum Discussion
anacpint
Helper I
4 years agoTotal value coming from measure is wrong
Hello, I developed this measure: CALCULATE(if([COUNTReport]=2, DIVIDE(SUM(FactOTDJnJPap[measurevalue]),2), SUM(FactOTDJnJPap[measurevalue])), FactOTDJnJPap[IDTypeReportJnJPharma] IN {1,5}) ...
- 4 years ago
Hi anacpint
Pleas tryOTD_TESTE = SUMX ( SUMMARIZE ( FactOTDJnJPap, DimSite[jnj_site], DimTypeReport[type_of_report] ), CALCULATE ( IF ( [COUNTReport] = 2, DIVIDE ( SUM ( FactOTDJnJPap[measurevalue] ), 2 ), SUM ( FactOTDJnJPap[measurevalue] ) ), FactOTDJnJPap[IDTypeReportJnJPharma] IN { 1, 5 } ) )
tamerj1
Community Champion
4 years agoHi anacpint
Pleas try
OTD_TESTE =
SUMX (
SUMMARIZE ( FactOTDJnJPap, DimSite[jnj_site], DimTypeReport[type_of_report] ),
CALCULATE (
IF (
[COUNTReport] = 2,
DIVIDE ( SUM ( FactOTDJnJPap[measurevalue] ), 2 ),
SUM ( FactOTDJnJPap[measurevalue] )
),
FactOTDJnJPap[IDTypeReportJnJPharma] IN { 1, 5 }
)
)