Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
4 years ago
Solved

Identifier low and higher values

Good afternoon, I seek to identify the values ​​greater than 500 and less than 500, that when the values ​​are greater than 500 tell me that it is not "NOT ELIGIBLE" and if they are less than 500 "YES ELIGIBLE"

  • TheoC's avatar
    TheoC
    4 years ago

    Hi Anonymous 

     

    Given the assessment is happening at the row level, a calculated column is appropriate for this. However, if you want to change the context, then:

     

    1. Create a Measure that sums the amount column

    Amount = SUM ( 'Table'[Precio $ / KV] )

    2. Create a second Measure such as:

    Measure = 

    SWITCH (
    TRUE () ,
    [Amount] < 500 , "NOT ELIGIBLE" ,
    [Amount] >= 500 , "YES ELIGIBLE" ,
    BLANK()
    )

    If you wanted to only have one measure, you can adjust it to the following:

     

    Measure = 

    SWITCH (
    TRUE () ,
    SUM ( 'Table'[Precio $ / KV] ) < 500 , "NOT ELIGIBLE" ,
    SUM ( 'Table'[Precio $ / KV] ) >= 500 , "YES ELIGIBLE" ,
    BLANK()
    )

    Hope this helps!

     

    Theo

5 Replies

  • TheoC's avatar
    TheoC
    Community Champion

    Hi Anonymous 

     

    You can create a calculated column as follows:

     

    Column = 

    SWITCH (
    TRUE () ,
    'Table'[Precio $ / KV] < 500 , "NOT ELIGIBLE" ,
    'Table'[Precio $ / KV] >= 500 , "YES ELIGIBLE" ,
    BLANK()
    )

     

    In the above, I have assumed you wanted 500 and greater than 500 hence I added ">=", not just greater than 500.  If you only want "greater than 500", then please remove the equals sign.

     

    Just check the name of the columns and update your "Table" to the table name you have.

     

    Hope this helps 🙂

     

    Theo

     

    • Anonymous's avatar
      Anonymous
      Not applicable

      TheoC Hello, thank you very much for answering my question. Do you know if there is any way to make it a measure?

      • TheoC's avatar
        TheoC
        Community Champion

        Hi Anonymous 

         

        Given the assessment is happening at the row level, a calculated column is appropriate for this. However, if you want to change the context, then:

         

        1. Create a Measure that sums the amount column

        Amount = SUM ( 'Table'[Precio $ / KV] )

        2. Create a second Measure such as:

        Measure = 

        SWITCH (
        TRUE () ,
        [Amount] < 500 , "NOT ELIGIBLE" ,
        [Amount] >= 500 , "YES ELIGIBLE" ,
        BLANK()
        )

        If you wanted to only have one measure, you can adjust it to the following:

         

        Measure = 

        SWITCH (
        TRUE () ,
        SUM ( 'Table'[Precio $ / KV] ) < 500 , "NOT ELIGIBLE" ,
        SUM ( 'Table'[Precio $ / KV] ) >= 500 , "YES ELIGIBLE" ,
        BLANK()
        )

        Hope this helps!

         

        Theo