Forum Discussion

fjones0409's avatar
fjones0409
Regular Visitor
6 years ago
Solved

Dax filtering for text value

Hi,

 

I have a table where 1 column just has data of type 'text', it is essentially a description colulmn. I am trying to use a dax measure in which i can return this text, when i filter by another column value. 

 

Does anyone know how i can achieve this? For number columns its easy as i can use calculate and sum or average but not sure how to do the same and have it return text?

 

ie for a number i use:

Desc = calculate(averagex(table3,Table3[Data]),filter(Table3,Table3[Scenario]=[S2 Scen input]))
 
How can i change this for text, what functions work with strings?
 
Thanks,
 
Francesca
  • hi fjones0409 

    for example, FIRSTNONBLANK()

    Desc = calculate(FIRSTNONBLANK(Table3[YourTextColumn], 1), filter(Table3,Table3[Scenario]= "something") )

1 Reply

  • az38's avatar
    az38
    Community Champion

    hi fjones0409 

    for example, FIRSTNONBLANK()

    Desc = calculate(FIRSTNONBLANK(Table3[YourTextColumn], 1), filter(Table3,Table3[Scenario]= "something") )