Forum Discussion

MEFOX's avatar
MEFOX
Icon for Helper III rankHelper III
5 years ago
Solved

Stacked Column Chart - removing axis items if the value field contains blank or zero

The description in the axis should not show up if there isnt a value greater then 0. Can some one tell me how to prevent the axis description from appearing? thanks

 

 

 

 

  • Can you try in the filters, advance filtering, is greater than zero?

  • Hi,

    Why not just this?

    Total Contacts = DISTINCTCOUNTNOBLANK('Shared FactEventHistory'[ContactID])

    Anyways, if you must show a 0, then try this measure

    Total Contacts = COALESCE(DISTINCTCOUNTNOBLANK('Shared FactEventHistory'[ContactID]),0)

5 Replies

    • MEFOX's avatar
      MEFOX
      Icon for Helper III rankHelper III

      The measure is 

      Total Contacts = if(
      ISBLANK(
      DISTINCTCOUNTNOBLANK('Shared FactEventHistory'[ContactID]))=TRUE(),
      0,
      DISTINCTCOUNTNOBLANK('Shared FactEventHistory'[ContactID]
      )
      )
      • Ashish_Mathur's avatar
        Ashish_Mathur
        Icon for Super User rankSuper User

        Hi,

        Why not just this?

        Total Contacts = DISTINCTCOUNTNOBLANK('Shared FactEventHistory'[ContactID])

        Anyways, if you must show a 0, then try this measure

        Total Contacts = COALESCE(DISTINCTCOUNTNOBLANK('Shared FactEventHistory'[ContactID]),0)

  • Can you try in the filters, advance filtering, is greater than zero?

  • It's very easy. You have to create a measure that will return 1 if you want to see the value and 0 if not. Then use this measure in the Filter Pane of the visual with a suitable condition.

     

    By the way, comparing a logical value to TRUE or FALSE is totally unnecessary since a logical value already is TRUE or FALSE.