Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
tatac1412
Helper I
Helper I

ayuda con dax para hacer un if con una variable tipo string

HOlaa necesito su ayuda estoy haciendo un dax para una tabla en donde pueda según el la variable  "IndicadorF" sea mayor a 90 y la variable "indicador_202_desc"= "Gestantes con fecha de parto o cesarea" me coloque el color de texto pero me saca error de que no me reconoce "indicador_202_desc".

tatac1412_0-1701985658777.png

El dax es este:

Metas = if('Resolución 202'[IndicadorF]>90 && 'Resolución 202'[indicador_202_desc]="Gestantes con fecha de parto o cesarea","#33C600")
 
Me ayudan porfa.
Gracias
1 REPLY 1
Anonymous
Not applicable

Hi @tatac1412 ,

Sorry but the information you've provided is too little for me to determine what your problem is.
First I suggest you check that the column name is spelled correctly. Then if you are working within a filter context, as in a measure, you may need to use the SELECTEDVALUE function to get the current value of the "indicator_202_desc" column:

SELECTEDVALUE('Resolución 202'[indicador_202_desc]) = "Gestantes con fecha de parto o cesarea"

If you still can't solve your problem, please provide more details, e.g. is this a metric or a calculated column? What is the data model of the data you are using?

Best Regards,
Dino Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.