Forum Discussion

Bryanna's avatar
Bryanna
Icon for Helper II rankHelper II
3 years ago

Roundup not summing correctly

Hi,

 

I am using the following measure to round up, however it is not summing correctly its just rounding the total. I found where someone wrote to use the following measure below, however this is on a column not a measure and my below measure will not populate where they have 'Crate EQ'. Any ideas?

 

ROUNDUP('Shipped Cases'[P/TL],0)
 
Round_new =
VAR _new =
    SUMMARIZE ( 'Table', 'Table'[Crate EQ], "_value", [_your roundup] )
RETURN
    IF (
        HASONEVALUE ( 'Table'[Crate EQ] ),
        [_your roundup],
        SUMX ( _new, [_value] )
    )

3 Replies

  • tamerj1's avatar
    tamerj1
    Icon for Community Champion rankCommunity Champion

    Bryanna 

    Please try

    Round_new =
    SUMX ( VALUES ( 'Table'[Crate EQ] ), [_your roundup] )

    • Bryanna's avatar
      Bryanna
      Icon for Helper II rankHelper II

      Looks like that was still missing counting some of the data. The below seemed to work however.

      Measure 4 = SUMX('Table',[_your roundup])
      • tamerj1's avatar
        tamerj1
        Icon for Community Champion rankCommunity Champion

        Bryanna 

        That depends on which granularity the visual represents. That was not clarified in the question therefore it was interpreted through your original dax code.