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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
chall069
Frequent Visitor

Necesita fórmula para devolver ciertos valores para objetos de diferentes tamaños

Estoy trabajando para crear una tarjeta de puntuación para una categoría. No sé si lo que estoy tratando de hacer es posible.

Me gustaría crear una función dax que compare todos los valores de texto (Tamaño) dentro de un grupo (Environment). Si los valores de texto no son los mismos dentro de un grupo determinado, debe devolver un 0 para el registro; si son los mismos dentro de un grupo dado, entonces devuelva un 1.

Consulte la tabla siguiente para saber cómo debería ser el resultado. Gracias por la ayuda!

AmbienteTamañoValor de retorno
DesarrolloStandard_B4ms0
DesarrolloStandard_B8ms0
ProducciónStandard_DS3_v20
ProducciónStandard_DS4_v20
QaStandard_DS3_v21
QaStandard_DS3_v21
EtapaStandard_DS3_v21
EtapaStandard_DS3_v21
UatStandard_DS3_v20
UatStandard_DS4_v20
3 REPLIES 3
nandic
Memorable Member
Memorable Member

@chall069 ,
Aquí está la fórmula:

Valor de retorno ?
SI(
CALCULATE(
DISTINCTCOUNT(Sheet1[Tamaño]),
ALLEXCEPT(Sheet1,Sheet1[Entorno]))>1,
0,1
)



Environment size.PNG

parry2k
Super User
Super User

@chall069 añadir la siguiente medida y eso lo hará

Measure = 
VAR __c =  CALCULATETABLE ( VALUES ( 'Table (2)'[Size] ), ALLEXCEPT ( 'Table (2)', 'Table (2)'[Environment] ) )
RETURN
IF ( COUNTROWS ( __c ) > 1, 0, 1 ) 

Me gustaría elogiossi mi solución ayudara.👉Si puedes pasar tiempo publicando la pregunta, también puedes hacer esfuerzos para dar a Kudos quien haya ayudado a resolver tu problema. ¡Es una muestra de agradecimiento!

Visítenos enhttps://perytus.com, su ventanilla única para proyectos/formación/consulta relacionadas con Power BI.



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

Gracias por la ayuda

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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

Top Solution Authors