Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Bom dia!
Gostaria de calcular os grupos abaixo aplicando a seguinte regra:
Se coluna GRUPO = Estado < 200 ERB's for maior que 15% (coluna %ERB´'s) então pinta de laranja
Se coluna GRUPO= Estado < 200 ERB's for maior que 25% (coluna %ERB´'s) então pinta de vermelho
Se não for maior que 15% e maior que 25% então deixar em branco.
Outro exemplo da caluna GRUPO ...
Se coluna GRUPO = Estado > 200 < 500 ERB's for maior que 15% (coluna %ERB´'s) então pinta de laranja
Se coluna GRUPO = Estado > 200 < 500 ERB's for maior que 25% (coluna %ERB´'s) então pinta de vermelho
Solved! Go to Solution.
Hi , @Victor1986
Based on the dax you wrote, I don't think there's anything wrong with your logic, you need to check the following points:
(1)Make sure you're writing Measure and putting it in the visual.
(2)Check if your [%ERB's] field format is a number type
(3)For the data you provide '2,35%' specifically means a few percent, you need to replace your comparison value yourself.(For your format '0,00%', I'm not very clear what the specific values represent)
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Olá, pessoal! Se você está interessado em aprimorar suas habilidades no Power BI, temos um vídeo super útil sobre formatação condicional que pode ajudar a tornar seus relatórios ainda mais dinâmicos e informativos: https://www.instagram.com/p/C7hm_e_Ir3t/
Além disso, no nosso blog da inQuesti, você encontrará uma variedade de conteúdos sobre Power BI que podem ajudar a otimizar suas análises e a criação de dashboards. Vale a pena conferir!
https://inquesti.com.br/blog/
Hi , @Victor1986
According to your description , you want to show different colors according to different conditions. Right?
Here are the steps you can refer to :
(1)This is my test data:
(2)We can create a measure:
Measure = var _grupo=SELECTEDVALUE('Sheet1'[GRUPO])
var _erb =SELECTEDVALUE('Sheet1'[%ERB's])
return
SWITCH(TRUE(),
_grupo = "Estado < 200 ERB's" , IF(_erb > 0.15 && _erb <0.25 , "orange" , IF(_erb >= 0.25 ,"red" , BLANK())),
_grupo = "Estado > 200 < 500 ERB's" , IF(_erb > 0.15 && _erb <0.25 , "orange" , IF(_erb >= 0.25 ,"red" , BLANK())),BLANK())
(3)We can put the measure to which filed we want to diplay colors:
(4)Then we can meet your need , the result is as follows:
If this method does not meet your needs, you can provide us with your special sample data and the desired output sample data in the form of tables, so that we can better help you solve the problem.
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Olá @v-yueyunzh-msft
Tudo bem?
utilizei a formula dax mencionada por vc conforme abaixo...no entando quando vou aplicala como formatação condicional aparece como não selecionavel... consegue me orientar aonde esta o erro e porque esta não selecionavel?
Hi, @Victor1986
If you use the measure to display the color, you need to select "Field value" in "Format style".
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Bom dia @v-yueyunzh-msft
Segui com o preenchimento da formula conforme abaixo e tambem utilizei como "valor do campo" ... a formula não apresentou erro e tambem não representou as cores.....
Formula:
Hi , @Victor1986
Based on the dax you wrote, I don't think there's anything wrong with your logic, you need to check the following points:
(1)Make sure you're writing Measure and putting it in the visual.
(2)Check if your [%ERB's] field format is a number type
(3)For the data you provide '2,35%' specifically means a few percent, you need to replace your comparison value yourself.(For your format '0,00%', I'm not very clear what the specific values represent)
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Desculpa, eu escrevo uma coisa aqui e publica outra diferente do que escrevi ...mais acho que vc entendeu .....
Check out the July 2025 Power BI update to learn about new features.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
User | Count |
---|---|
23 | |
10 | |
10 | |
9 | |
7 |