The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hola a todos
Quiero calcular la diferencia %, dando 9 condición mencionada a continuación para cada cálculo de nivel de fila.
S.No | CURP | Urp | SFRP | Diferencia % | Dax para cada cálculo de nivel de fila |
1 | N/A | SI las tres columnas están en blanco | |||
2 | 100 | 90 | (90/100)% | SFRP/CURP. Cuando URP está en blanco | |
3 | 50 | 90 | (90/50)% | SFRP/URP. Cuando CURP está en blanco | |
4 | 90 | (90/1)% | SFRP/1. Cuando CURP y URP están en blanco | ||
5 | 100 | (1/100)% | 1/CURP. Cuando SFRP y URP están en blanco | ||
6 | 50 | (1/50)% | 1/URP. Cuando SFRP y CURP están en blanco | ||
7 | 100 | 100 | 100 | (100/100)% - 0% | Debe ser 0% cuando todos tienen el mismo valor |
8 | 0 | 100 | 50 | 50% | Cuando CURP es 0 considere el valor SFRP como Porcentaje |
9 | 0 | 0 | 50 | 50% | Cuando CURP y URP son 0, considere el valor SFRP como Porcentaje |
10 | 0 | 0 | 0 | 0% | Cuando CURP, URP y SFRP son 0, considere el valor como Porcentaje |
Por favor, compruebe y corríjame si por debajo de DAX es correcto para la Condición 2 a 6 que intenté.
Diffirent% =
PBI trabajando
saludos
Hari
Solved! Go to Solution.
Hola @harirao ,
Para la medida, utilice lo siguiente:
Medida de Porcentajedesa
INTERRUPTOR (
VERDADERO (),
Condición No.1
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Data'[URP-Unconstrained Requirement Plan] )
) á 0
&& SUM ( 'Datos'[CURP-Consolidated URP] ) > 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0, DIVIDE (
SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ),
SUM ( 'Datos'[URP consolidado CURP] )
),
Condición No.2
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) á 0
&& SUM ( 'Data'[URP-Unconstrained Requirement Plan] ) > 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0, DIVIDE (
SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ),
SUM ( 'Datos'[Plan de requisitos sin restricciones URP] )
),
Condición No.3
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) )
) á 0
&& SUM ( 'Datos'[URP consolidado CURP] ) > 0, DIVIDE ( 1, SUM ( 'Data'[CURP-Consolidated URP] ) ),
Condición No.4
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) á 0
&& CALCULATE (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Data'[URP-Unconstrained Requirement Plan] )
) á 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0, DIVIDE ( SUM ( 'Data' [SFRP- Submitted Final Requirement Plan] ), 100 ),
Condición No.19
SUM ( 'Datos'[URP consolidado CURP] ) - 0
&& SUM ( 'Datos'[URP-Plan de requisitos sin restricciones] )
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0, DIVIDE ( SUM ( 'Data' [SFRP- Submitted Final Requirement Plan] ), 100 ),
Condición No.6
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) )
) á 0
&& CALCULATE (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) á 0
&& SUM ( 'Datos'[URP-Plan de requisitos sin restricciones] ) > 0, DIVIDE ( 1, SUM ( 'Data'[URP-Unconstrained Requirement Plan] ) ),
Condición No.7
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Data'[URP-Unconstrained Requirement Plan] )
) á 0
&& CALCULATE (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) )
) á 0
&& CALCULATE (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) - 0, 0,
Condición No.8 y Condición No.9
SUM ( 'Datos'[Plan de requisitos sin restricciones URP] )
• SUM ('Datos'[SFRP- Plan de requisitos finales presentado] )
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] )
• SUM ( 'Datos'[URP consolidado CURP] ), 0,
Condición No.10 y Condición No.12
SUM ( [CURP-Consolidated URP] ) - 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0
&& SUM ( 'Datos'[URP-Plan de requisitos sin restricciones] ) > 0, DIVIDE ( SUM ( 'Data' [SFRP- Submitted Final Requirement Plan] ), 100 ),
Condición No.11
SUM ( 'Datos'[URP-Plan de requisitos sin restricciones] ) - 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0
&& SUM ( 'Datos'[URP consolidado CURP] ) > 0, DIVIDE (
SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ),
SUM ( 'Datos'[URP consolidado CURP] )
),
Condición No.13
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Data'[URP-Unconstrained Requirement Plan] )
) á 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0
&& SUM ( 'Datos'[URP consolidado CURP] ) - 0, DIVIDE ( SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ), 100 ),
Condición No.14
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) á 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0
&& SUM ( 'Datos'[URP-Plan de requisitos sin restricciones] ) - 0, DIVIDE ( SUM ( 'Data'[SFRP- Submitted Final Requirement Plan] ), 100 ),
Condición No.15 y Condición No.16 y Condición No.17
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) )
) á 0
&& (
SUM ( 'Datos'[URP consolidado CURP] ) - 0
|| CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) á 0
), 0,
Condición No.18
SUM ( 'Datos'[SFRP- Presentado FinalPlan de requisitos] ) , 0, 0,
Condición predeterminada
DIVIDE (
SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ),
SUM ( 'Datos'[URP consolidado CURP] ),
0 )
)
Para el mismo número, creemos que puede porque es un número decimel pero mostrar como número entero.
Para coulmn:
Diffirent% Column =
SWITCH (
TRUE (),
//Condition No.1
ISBLANK ( [URP-Unconstrained Requirement Plan] )
&& [CURP-Consolidated URP] > 0
&& [SFRP- Submitted Final Requirement Plan] > 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], [CURP-Consolidated URP] ),
//Condition No.2
ISBLANK ( [CURP-Consolidated URP] )
&& [URP-Unconstrained Requirement Plan] > 0
&& [SFRP- Submitted Final Requirement Plan] > 0, DIVIDE (
[SFRP- Submitted Final Requirement Plan],
[URP-Unconstrained Requirement Plan]
),
//Condition No.3
ISBLANK ( [SFRP- Submitted Final Requirement Plan] )
&& [CURP-Consolidated URP] > 0, DIVIDE ( 1, [CURP-Consolidated URP] ),
//Condition No.4
ISBLANK ( [CURP-Consolidated URP] )
&& ISBLANK ( [URP-Unconstrained Requirement Plan] )
&& [SFRP- Submitted Final Requirement Plan] > 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], 100 ),
//Condition No.19
[CURP-Consolidated URP] = 0
&& [URP-Unconstrained Requirement Plan] = 0
&& [SFRP- Submitted Final Requirement Plan] > 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], 100 ),
//Condition No.6
ISBLANK ( [SFRP- Submitted Final Requirement Plan] )
&& ISBLANK ( [CURP-Consolidated URP] )
&& [URP-Unconstrained Requirement Plan] > 0, DIVIDE ( 1, [URP-Unconstrained Requirement Plan] ),
//Condition No.7
ISBLANK ( [URP-Unconstrained Requirement Plan] )
&& ISBLANK ( [SFRP- Submitted Final Requirement Plan] )
&& ISBLANK ( [CURP-Consolidated URP] ), 0,
//Condition No.8 & Condition No.9
ROUND (
[URP-Unconstrained Requirement Plan],
0
)
= ROUND ( [SFRP- Submitted Final Requirement Plan], 0 )
&& ROUND ( [SFRP- Submitted Final Requirement Plan], 0 )
= ROUND ( [CURP-Consolidated URP], 0 ), 0,
//Condition No.10 & Condition No.12
[CURP-Consolidated URP] = 0
&& [SFRP- Submitted Final Requirement Plan] > 0
&& [URP-Unconstrained Requirement Plan] > 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], 100 ),
//Condition No.11
[URP-Unconstrained Requirement Plan] = 0
&& [SFRP- Submitted Final Requirement Plan] > 0
&& [CURP-Consolidated URP] > 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], [CURP-Consolidated URP] ),
//Condition No.13
ISBLANK ( [URP-Unconstrained Requirement Plan] )
&& [SFRP- Submitted Final Requirement Plan] > 0
&& [CURP-Consolidated URP] = 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], 100 ),
//Condition No.14
ISBLANK ( [CURP-Consolidated URP] )
&& [SFRP- Submitted Final Requirement Plan] > 0
&& [URP-Unconstrained Requirement Plan] = 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], 100 ),
//Condition No.15 & Condition No.16 & Condition No.17
ISBLANK ( [SFRP- Submitted Final Requirement Plan] )
&& (
[CURP-Consolidated URP] = 0
|| ISBLANK ( [CURP-Consolidated URP] )
), 0,
//Condition No.18
[SFRP- Submitted Final Requirement Plan] = 0, 0,
//Default Condition
DIVIDE (
[SFRP- Submitted Final Requirement Plan],
[CURP-Consolidated URP],
0
)
)
Para la medida:
Medida de Porcentajedesa
INTERRUPTOR (
VERDADERO (),
Condición No.1
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Data'[URP-Unconstrained Requirement Plan] )
) á 0
&& SUM ( 'Datos'[CURP-Consolidated URP] ) > 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0, DIVIDE (
SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ),
SUM ( 'Datos'[URP consolidado CURP] )
),
Condición No.2
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) á 0
&& SUM ( 'Data'[URP-Unconstrained Requirement Plan] ) > 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0, DIVIDE (
SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ),
SUM ( 'Datos'[Plan de requisitos sin restricciones URP] )
),
Condición No.3
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) )
) á 0
&& SUM ( 'Datos'[URP consolidado CURP] ) > 0, DIVIDE ( 1, SUM ( 'Data'[CURP-Consolidated URP] ) ),
Condición No.4
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) á 0
&& CALCULATE (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Data'[URP-Unconstrained Requirement Plan] )
) á 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0, DIVIDE ( SUM ( 'Data' [SFRP- Submitted Final Requirement Plan] ), 100 ),
Condición No.19
SUM ( 'Datos'[URP consolidado CURP] ) - 0
&& SUM ( 'Datos'[URP-Plan de requisitos sin restricciones] )
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0, DIVIDE ( SUM ( 'Data' [SFRP- Submitted Final Requirement Plan] ), 100 ),
Condición No.6
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) )
) á 0
&& CALCULATE (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) á 0
&& SUM ( 'Datos'[URP-Plan de requisitos sin restricciones] ) > 0, DIVIDE ( 1, SUM ( 'Data'[URP-Unconstrained Requirement Plan] ) ),
Condición No.7
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Data'[URP-Unconstrained Requirement Plan] )
) á 0
&& CALCULATE (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) )
) á 0
&& CALCULATE (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) - 0, 0,
Condición No.8 y Condición No.9
ROUND (
SUM ( 'Datos'[Plan de requisitos sin restricciones URP] ),
0
)
• ROUND ( SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ), 0 )
&& ROUND ( SUM ( 'Data'[SFRP- Submitted Final Requirement Plan] ), 0 )
• ROUND ( SUM ( 'Datos'[URP consolidado CURP] ), 0 ), 0,
Condición No.10 y Condición No.12
SUM ( [CURP-Consolidated URP] ) - 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0
&& SUM ( 'Datos'[URP-Plan de requisitos sin restricciones] ) > 0, DIVIDE ( SUM ( 'Data' [SFRP- Submitted Final Requirement Plan] ), 100 ),
Condición No.11
SUM ( 'Datos'[URP-Plan de requisitos sin restricciones] ) - 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0
&& SUM ( 'Datos'[URP consolidado CURP] ) > 0, DIVIDE (
SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ),
SUM ( 'Datos'[URP consolidado CURP] )
),
Condición No.13
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Data'[URP-Unconstrained Requirement Plan] )
) á 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0
&& SUM ( 'Datos'[URP consolidado CURP] ) - 0, DIVIDE ( SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ), 100 ),
Condición No.14
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) á 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0
&& SUM ( 'Datos'[URP-Plan de requisitos sin restricciones] ) - 0, DIVIDE ( SUM ( 'Data'[SFRP- Submitted Final Requirement Plan] ), 100 ),
Condición No.15 y Condición No.16 y Condición No.17
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) )
) á 0
&& (
SUM ( 'Datos'[URP consolidado CURP] ) - 0
|| CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) á 0), 0,
Condición No.18
SUM ( 'Datos'[SFRP- Plan de requisitos finales presentados] ) - 0, 0,
Condición predeterminada
DIVIDE (
SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ),
SUM ( 'Datos'[URP consolidado CURP] ),
0 )
)
Saludos
Hola @v miembro-msft ,
Gracias por su respone, una pequeña actualización requerida de usted
La condición 3 no está funcionando cuando SFRP está en blanco, por defecto tenemos que considerarlo como 1 resultado debe ser (1/75-1%, 1/8-13%) pero estoy recibiendo 0% que está mal según nuestras condiciones.
saludos
Día
Hola @harirao ,
Utilice lo siguiente , encontramos que la Condición 5 y la Condición 3 son las mismas, por lo que eliminamos una.
Para columna:
Diffirent% Column =
SWITCH (
TRUE (),
//Condition No.1
ISBLANK ( [URP-Unconstrained Requirement Plan] )
&& [CURP-Consolidated URP] > 0
&& [SFRP- Submitted Final Requirement Plan] > 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], [CURP-Consolidated URP] ),
//Condition No.2
ISBLANK ( [CURP-Consolidated URP] )
&& [URP-Unconstrained Requirement Plan] > 0
&& [SFRP- Submitted Final Requirement Plan] > 0, DIVIDE (
[SFRP- Submitted Final Requirement Plan],
[URP-Unconstrained Requirement Plan]
),
//Condition No.3
ISBLANK ( [SFRP- Submitted Final Requirement Plan] )
&& [CURP-Consolidated URP] > 0, DIVIDE ( 1, [CURP-Consolidated URP] ),
//Condition No.4
ISBLANK ( [CURP-Consolidated URP] )
&& ISBLANK ( [URP-Unconstrained Requirement Plan] )
&& [SFRP- Submitted Final Requirement Plan] > 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], 100 ),
//Condition No.19
[CURP-Consolidated URP] = 0
&& [URP-Unconstrained Requirement Plan] = 0
&& [SFRP- Submitted Final Requirement Plan] > 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], 100 ),
//Condition No.6
ISBLANK ( [SFRP- Submitted Final Requirement Plan] )
&& ISBLANK ( [CURP-Consolidated URP] )
&& [URP-Unconstrained Requirement Plan] > 0, DIVIDE ( 1, [URP-Unconstrained Requirement Plan] ),
//Condition No.7
ISBLANK ( [URP-Unconstrained Requirement Plan] )
&& ISBLANK ( [SFRP- Submitted Final Requirement Plan] )
&& ISBLANK ( [CURP-Consolidated URP] ), 0,
//Condition No.8 & Condition No.9
[URP-Unconstrained Requirement Plan] = [SFRP- Submitted Final Requirement Plan]
&& [SFRP- Submitted Final Requirement Plan] = [CURP-Consolidated URP], 0,
//Condition No.10 & Condition No.12
[CURP-Consolidated URP] = 0
&& [SFRP- Submitted Final Requirement Plan] > 0
&& [URP-Unconstrained Requirement Plan] > 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], 100 ),
//Condition No.11
[URP-Unconstrained Requirement Plan] = 0
&& [SFRP- Submitted Final Requirement Plan] > 0
&& [CURP-Consolidated URP] > 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], [CURP-Consolidated URP] ),
//Condition No.13
ISBLANK ( [URP-Unconstrained Requirement Plan] )
&& [SFRP- Submitted Final Requirement Plan] > 0
&& [CURP-Consolidated URP] = 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], 100 ),
//Condition No.14
ISBLANK ( [CURP-Consolidated URP] )
&& [SFRP- Submitted Final Requirement Plan] > 0
&& [URP-Unconstrained Requirement Plan] = 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], 100 ),
//Condition No.15 & Condition No.16 & Condition No.17
ISBLANK ( [SFRP- Submitted Final Requirement Plan] )
&& (
[CURP-Consolidated URP] = 0
|| ISBLANK ( [CURP-Consolidated URP] )
), 0,
//Condition No.18
[SFRP- Submitted Final Requirement Plan] = 0, 0,
//Default Condition
DIVIDE (
[SFRP- Submitted Final Requirement Plan],
[CURP-Consolidated URP],
0
)
)
Para la medida:
Diffirent% Column =
SWITCH (
TRUE (),
//Condition No.1
CALCULATE (
COUNTROWS ( 'Data' ),
NOT ( ISBLANK ( 'Data'[URP-Unconstrained Requirement Plan] ) )
) = 0
&& [CURP-Consolidated URP] > 0
&& SUM ( [SFRP- Submitted Final Requirement Plan] ) > 0, DIVIDE (
SUM ( [SFRP- Submitted Final Requirement Plan] ),
SUM ( [CURP-Consolidated URP] )
),
//Condition No.2
CALCULATE (
COUNTROWS ( 'Data' ),
NOT ( ISBLANK ( 'Data'[CURP-Consolidated URP] ) )
) = 0
&& SUM ( [URP-Unconstrained Requirement Plan] ) > 0
&& SUM ( [SFRP- Submitted Final Requirement Plan] ) > 0, DIVIDE (
SUM ( [SFRP- Submitted Final Requirement Plan] ),
SUM ( [URP-Unconstrained Requirement Plan] )
),
//Condition No.3
CALCULATE (
COUNTROWS ( 'Data' ),
NOT ( ISBLANK ( 'Data'[SFRP- Submitted Final Requirement Plan] ) )
) = 0
&& [CURP-Consolidated URP] > 0, DIVIDE ( 1, SUM ( [CURP-Consolidated URP] ) ),
//Condition No.4
CALCULATE (
COUNTROWS ( 'Data' ),
NOT ( ISBLANK ( 'Data'[CURP-Consolidated URP] ) )
) = 0
&& CALCULATE (
COUNTROWS ( 'Data' ),
NOT ( ISBLANK ( 'Data'[URP-Unconstrained Requirement Plan] ) )
) = 0
&& SUM ( [SFRP- Submitted Final Requirement Plan] ) > 0, DIVIDE ( SUM ( [SFRP- Submitted Final Requirement Plan] ), 100 ),
//Condition No.19
SUM ( [CURP-Consolidated URP] ) = 0
&& SUM ( [URP-Unconstrained Requirement Plan] ) = 0
&& SUM ( [SFRP- Submitted Final Requirement Plan] ) > 0, DIVIDE ( SUM ( [SFRP- Submitted Final Requirement Plan] ), 100 ),
//Condition No.6
CALCULATE (
COUNTROWS ( 'Data' ),
NOT ( ISBLANK ( 'Data'[SFRP- Submitted Final Requirement Plan] ) )
) = 0
&& CALCULATE (
COUNTROWS ( 'Data' ),
NOT ( ISBLANK ( 'Data'[CURP-Consolidated URP] ) )
) = 0
&& SUM ( [URP-Unconstrained Requirement Plan] ) > 0, DIVIDE ( 1, SUM ( [URP-Unconstrained Requirement Plan] ) ),
//Condition No.7
CALCULATE (
COUNTROWS ( 'Data' ),
NOT ( ISBLANK ( 'Data'[URP-Unconstrained Requirement Plan] ) )
) = 0
&& CALCULATE (
COUNTROWS ( 'Data' ),
NOT ( ISBLANK ( 'Data'[SFRP- Submitted Final Requirement Plan] ) )
) = 0
&& CALCULATE (
COUNTROWS ( 'Data' ),
NOT ( ISBLANK ( 'Data'[CURP-Consolidated URP] ) )
) = 0, 0,
//Condition No.8 & Condition No.9
[URP-Unconstrained Requirement Plan] = [SFRP- Submitted Final Requirement Plan]
&& [SFRP- Submitted Final Requirement Plan] = [CURP-Consolidated URP], 0,
//Condition No.10 & Condition No.12
SUM ( [CURP-Consolidated URP] ) = 0
&& SUM ( [SFRP- Submitted Final Requirement Plan] ) > 0
&& SUM ( [URP-Unconstrained Requirement Plan] ) > 0, DIVIDE ( SUM ( [SFRP- Submitted Final Requirement Plan] ), 100 ),
//Condition No.11
SUM ( [URP-Unconstrained Requirement Plan] ) = 0
&& SUM ( [SFRP- Submitted Final Requirement Plan] ) > 0
&& [CURP-Consolidated URP] > 0, DIVIDE (
SUM ( [SFRP- Submitted Final Requirement Plan] ),
SUM ( [CURP-Consolidated URP] )
),
//Condition No.13
CALCULATE (
COUNTROWS ( 'Data' ),
NOT ( ISBLANK ( 'Data'[URP-Unconstrained Requirement Plan] ) )
) = 0
&& SUM ( [SFRP- Submitted Final Requirement Plan] ) > 0
&& SUM ( [CURP-Consolidated URP] ) = 0, DIVIDE ( SUM ( [SFRP- Submitted Final Requirement Plan] ), 100 ),
//Condition No.14
CALCULATE (
COUNTROWS ( 'Data' ),
NOT ( ISBLANK ( 'Data'[CURP-Consolidated URP] ) )
) = 0
&& SUM ( [SFRP- Submitted Final Requirement Plan] ) > 0
&& SUM ( [URP-Unconstrained Requirement Plan] ) = 0, DIVIDE ( SUM ( [SFRP- Submitted Final Requirement Plan] ), 100 ),
//Condition No.15 & Condition No.16 & Condition No.17
CALCULATE (
COUNTROWS ( 'Data' ),
NOT ( ISBLANK ( 'Data'[SFRP- Submitted Final Requirement Plan] ) )
) = 0
&& (
SUM ( [CURP-Consolidated URP] ) = 0
|| CALCULATE (
COUNTROWS ( 'Data' ),
NOT ( ISBLANK ( 'Data'[CURP-Consolidated URP] ) )
) = 0
), 0,
//Condition No.18
SUM ( [SFRP- Submitted Final Requirement Plan] ) = 0, 0,
//Default Condition
DIVIDE (
SUM ( [SFRP- Submitted Final Requirement Plan] ),
SUM ( [CURP-Consolidated URP] ),
0
)
)
Saludos
Hola @v-lid-msft
Después de implementar, por encima de la deferencia% Columna, pocas condiciones no están calculando correctamente
ID de producto | CURP | Urp | SFRP | Condición -8 | Debe ser 0% cuando todos tienen el mismo valor |
863180-001 | 7 | 7 | 7 | 0% | |
866987-001 | 1 | 1 | 1 | 0% | |
863180-001 | 6 | 6 | 6 | 0% | |
866987-001 | 1 | 1 | 1 | 0% | |
ID de producto | CURP | Urp | SFRP | Condición -1 | DEFAULT: SFRP/CURP |
863285-001 | 1 | 1 | 5 | 500% | |
866974-001 | 1 | 1 | 3 | 300% | |
863285-001 | 1 | 1 | 5 | 500% | |
866974-001 | 1 | 1 | 3 | 300% |
Por favor, ayúdame en lo anterior.
Nota: No puedo utilizar la medida, como obtener por debajo del error en las condiciones 1, 3, 8, 9 y 11
Gracias y saludos,
Hari
Hola @v miembro-msft ,
¿Puede usted por favor ayudarme en la corrección de problemas anteriores en pocas condiciones
saludos
Día
Hola @harirao ,
Para la medida, utilice lo siguiente:
Medida de Porcentajedesa
INTERRUPTOR (
VERDADERO (),
Condición No.1
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Data'[URP-Unconstrained Requirement Plan] )
) á 0
&& SUM ( 'Datos'[CURP-Consolidated URP] ) > 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0, DIVIDE (
SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ),
SUM ( 'Datos'[URP consolidado CURP] )
),
Condición No.2
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) á 0
&& SUM ( 'Data'[URP-Unconstrained Requirement Plan] ) > 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0, DIVIDE (
SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ),
SUM ( 'Datos'[Plan de requisitos sin restricciones URP] )
),
Condición No.3
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) )
) á 0
&& SUM ( 'Datos'[URP consolidado CURP] ) > 0, DIVIDE ( 1, SUM ( 'Data'[CURP-Consolidated URP] ) ),
Condición No.4
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) á 0
&& CALCULATE (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Data'[URP-Unconstrained Requirement Plan] )
) á 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0, DIVIDE ( SUM ( 'Data' [SFRP- Submitted Final Requirement Plan] ), 100 ),
Condición No.19
SUM ( 'Datos'[URP consolidado CURP] ) - 0
&& SUM ( 'Datos'[URP-Plan de requisitos sin restricciones] )
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0, DIVIDE ( SUM ( 'Data' [SFRP- Submitted Final Requirement Plan] ), 100 ),
Condición No.6
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) )
) á 0
&& CALCULATE (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) á 0
&& SUM ( 'Datos'[URP-Plan de requisitos sin restricciones] ) > 0, DIVIDE ( 1, SUM ( 'Data'[URP-Unconstrained Requirement Plan] ) ),
Condición No.7
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Data'[URP-Unconstrained Requirement Plan] )
) á 0
&& CALCULATE (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) )
) á 0
&& CALCULATE (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) - 0, 0,
Condición No.8 y Condición No.9
SUM ( 'Datos'[Plan de requisitos sin restricciones URP] )
• SUM ('Datos'[SFRP- Plan de requisitos finales presentado] )
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] )
• SUM ( 'Datos'[URP consolidado CURP] ), 0,
Condición No.10 y Condición No.12
SUM ( [CURP-Consolidated URP] ) - 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0
&& SUM ( 'Datos'[URP-Plan de requisitos sin restricciones] ) > 0, DIVIDE ( SUM ( 'Data' [SFRP- Submitted Final Requirement Plan] ), 100 ),
Condición No.11
SUM ( 'Datos'[URP-Plan de requisitos sin restricciones] ) - 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0
&& SUM ( 'Datos'[URP consolidado CURP] ) > 0, DIVIDE (
SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ),
SUM ( 'Datos'[URP consolidado CURP] )
),
Condición No.13
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Data'[URP-Unconstrained Requirement Plan] )
) á 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0
&& SUM ( 'Datos'[URP consolidado CURP] ) - 0, DIVIDE ( SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ), 100 ),
Condición No.14
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) á 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0
&& SUM ( 'Datos'[URP-Plan de requisitos sin restricciones] ) - 0, DIVIDE ( SUM ( 'Data'[SFRP- Submitted Final Requirement Plan] ), 100 ),
Condición No.15 y Condición No.16 y Condición No.17
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) )
) á 0
&& (
SUM ( 'Datos'[URP consolidado CURP] ) - 0
|| CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) á 0
), 0,
Condición No.18
SUM ( 'Datos'[SFRP- Presentado FinalPlan de requisitos] ) , 0, 0,
Condición predeterminada
DIVIDE (
SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ),
SUM ( 'Datos'[URP consolidado CURP] ),
0 )
)
Para el mismo número, creemos que puede porque es un número decimel pero mostrar como número entero.
Para coulmn:
Diffirent% Column =
SWITCH (
TRUE (),
//Condition No.1
ISBLANK ( [URP-Unconstrained Requirement Plan] )
&& [CURP-Consolidated URP] > 0
&& [SFRP- Submitted Final Requirement Plan] > 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], [CURP-Consolidated URP] ),
//Condition No.2
ISBLANK ( [CURP-Consolidated URP] )
&& [URP-Unconstrained Requirement Plan] > 0
&& [SFRP- Submitted Final Requirement Plan] > 0, DIVIDE (
[SFRP- Submitted Final Requirement Plan],
[URP-Unconstrained Requirement Plan]
),
//Condition No.3
ISBLANK ( [SFRP- Submitted Final Requirement Plan] )
&& [CURP-Consolidated URP] > 0, DIVIDE ( 1, [CURP-Consolidated URP] ),
//Condition No.4
ISBLANK ( [CURP-Consolidated URP] )
&& ISBLANK ( [URP-Unconstrained Requirement Plan] )
&& [SFRP- Submitted Final Requirement Plan] > 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], 100 ),
//Condition No.19
[CURP-Consolidated URP] = 0
&& [URP-Unconstrained Requirement Plan] = 0
&& [SFRP- Submitted Final Requirement Plan] > 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], 100 ),
//Condition No.6
ISBLANK ( [SFRP- Submitted Final Requirement Plan] )
&& ISBLANK ( [CURP-Consolidated URP] )
&& [URP-Unconstrained Requirement Plan] > 0, DIVIDE ( 1, [URP-Unconstrained Requirement Plan] ),
//Condition No.7
ISBLANK ( [URP-Unconstrained Requirement Plan] )
&& ISBLANK ( [SFRP- Submitted Final Requirement Plan] )
&& ISBLANK ( [CURP-Consolidated URP] ), 0,
//Condition No.8 & Condition No.9
ROUND (
[URP-Unconstrained Requirement Plan],
0
)
= ROUND ( [SFRP- Submitted Final Requirement Plan], 0 )
&& ROUND ( [SFRP- Submitted Final Requirement Plan], 0 )
= ROUND ( [CURP-Consolidated URP], 0 ), 0,
//Condition No.10 & Condition No.12
[CURP-Consolidated URP] = 0
&& [SFRP- Submitted Final Requirement Plan] > 0
&& [URP-Unconstrained Requirement Plan] > 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], 100 ),
//Condition No.11
[URP-Unconstrained Requirement Plan] = 0
&& [SFRP- Submitted Final Requirement Plan] > 0
&& [CURP-Consolidated URP] > 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], [CURP-Consolidated URP] ),
//Condition No.13
ISBLANK ( [URP-Unconstrained Requirement Plan] )
&& [SFRP- Submitted Final Requirement Plan] > 0
&& [CURP-Consolidated URP] = 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], 100 ),
//Condition No.14
ISBLANK ( [CURP-Consolidated URP] )
&& [SFRP- Submitted Final Requirement Plan] > 0
&& [URP-Unconstrained Requirement Plan] = 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], 100 ),
//Condition No.15 & Condition No.16 & Condition No.17
ISBLANK ( [SFRP- Submitted Final Requirement Plan] )
&& (
[CURP-Consolidated URP] = 0
|| ISBLANK ( [CURP-Consolidated URP] )
), 0,
//Condition No.18
[SFRP- Submitted Final Requirement Plan] = 0, 0,
//Default Condition
DIVIDE (
[SFRP- Submitted Final Requirement Plan],
[CURP-Consolidated URP],
0
)
)
Para la medida:
Medida de Porcentajedesa
INTERRUPTOR (
VERDADERO (),
Condición No.1
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Data'[URP-Unconstrained Requirement Plan] )
) á 0
&& SUM ( 'Datos'[CURP-Consolidated URP] ) > 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0, DIVIDE (
SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ),
SUM ( 'Datos'[URP consolidado CURP] )
),
Condición No.2
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) á 0
&& SUM ( 'Data'[URP-Unconstrained Requirement Plan] ) > 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0, DIVIDE (
SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ),
SUM ( 'Datos'[Plan de requisitos sin restricciones URP] )
),
Condición No.3
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) )
) á 0
&& SUM ( 'Datos'[URP consolidado CURP] ) > 0, DIVIDE ( 1, SUM ( 'Data'[CURP-Consolidated URP] ) ),
Condición No.4
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) á 0
&& CALCULATE (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Data'[URP-Unconstrained Requirement Plan] )
) á 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0, DIVIDE ( SUM ( 'Data' [SFRP- Submitted Final Requirement Plan] ), 100 ),
Condición No.19
SUM ( 'Datos'[URP consolidado CURP] ) - 0
&& SUM ( 'Datos'[URP-Plan de requisitos sin restricciones] )
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0, DIVIDE ( SUM ( 'Data' [SFRP- Submitted Final Requirement Plan] ), 100 ),
Condición No.6
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) )
) á 0
&& CALCULATE (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) á 0
&& SUM ( 'Datos'[URP-Plan de requisitos sin restricciones] ) > 0, DIVIDE ( 1, SUM ( 'Data'[URP-Unconstrained Requirement Plan] ) ),
Condición No.7
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Data'[URP-Unconstrained Requirement Plan] )
) á 0
&& CALCULATE (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) )
) á 0
&& CALCULATE (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) - 0, 0,
Condición No.8 y Condición No.9
ROUND (
SUM ( 'Datos'[Plan de requisitos sin restricciones URP] ),
0
)
• ROUND ( SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ), 0 )
&& ROUND ( SUM ( 'Data'[SFRP- Submitted Final Requirement Plan] ), 0 )
• ROUND ( SUM ( 'Datos'[URP consolidado CURP] ), 0 ), 0,
Condición No.10 y Condición No.12
SUM ( [CURP-Consolidated URP] ) - 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0
&& SUM ( 'Datos'[URP-Plan de requisitos sin restricciones] ) > 0, DIVIDE ( SUM ( 'Data' [SFRP- Submitted Final Requirement Plan] ), 100 ),
Condición No.11
SUM ( 'Datos'[URP-Plan de requisitos sin restricciones] ) - 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0
&& SUM ( 'Datos'[URP consolidado CURP] ) > 0, DIVIDE (
SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ),
SUM ( 'Datos'[URP consolidado CURP] )
),
Condición No.13
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Data'[URP-Unconstrained Requirement Plan] )
) á 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0
&& SUM ( 'Datos'[URP consolidado CURP] ) - 0, DIVIDE ( SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ), 100 ),
Condición No.14
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) á 0
&& SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) > 0
&& SUM ( 'Datos'[URP-Plan de requisitos sin restricciones] ) - 0, DIVIDE ( SUM ( 'Data'[SFRP- Submitted Final Requirement Plan] ), 100 ),
Condición No.15 y Condición No.16 y Condición No.17
CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[SFRP- Plan de requisitos finales presentado] ) )
) á 0
&& (
SUM ( 'Datos'[URP consolidado CURP] ) - 0
|| CALCULAR (
COUNTROWS ( 'Datos' ),
NOT ( ISBLANK ( 'Datos'[URP consolidado CURP] )
) á 0), 0,
Condición No.18
SUM ( 'Datos'[SFRP- Plan de requisitos finales presentados] ) - 0, 0,
Condición predeterminada
DIVIDE (
SUM ( 'Datos'[SFRP- Plan de requisitos finales presentado] ),
SUM ( 'Datos'[URP consolidado CURP] ),
0 )
)
Saludos
Hola @v-lid-msft,
Gracias por su respuesta, quiero crear otra medida / columna para la diferencia (resaltado en azul), como se menciona a continuación.
puede sordrme en esto usando las mismas 18 condiciones.
saludos
Hari
Hola @v-miembro-msft,
¿Puede por favor ayudarme en los problemas de corrección anteriores en pocas condiciones
saludos
Día
Hola @harirao ,
Parece un nuevo requisito, le sugerimos que lo publique en un nuevo hilo, haría que otros sean más fáciles de centrarse en una pregunta en un solo hilo y beneficiará a otros miembros de la comunidad que se quedaron con el mismo requisito.
Saludos
Hola v-member-msft,
Gracias por su respuesta, todavía recibiendo pocos espacios en blanco, por lo que he reelaborado en las condiciones añadir algunos más, para los cálculos de nivel de fila requeridos Resultado según la tabla siguiente
Puede ayudar en el cálculo de DAX:
saludos
Día
Hola @harirao ,
Por favor, intente utilizar la siguiente fórmula:
Diffirent% Column =
SWITCH (
TRUE (),
//condition No. 1
ISBLANK ( [URP-Unconstrained Requirement Plan] )
&& ISBLANK ( [SFRP- Submitted Final Requirement Plan] )
&& ISBLANK ( [CURP-Consolidated URP] ), BLANK (),
//condition No. 4
ISBLANK ( [CURP-Consolidated URP] )
&& (
ISBLANK ( [URP-Unconstrained Requirement Plan] )
|| [URP-Unconstrained Requirement Plan] = 0
), DIVIDE ( [SFRP- Submitted Final Requirement Plan], 1 ) / 100,
//condition No. 5
ISBLANK ( [SFRP- Submitted Final Requirement Plan] )
&& ISBLANK ( [URP-Unconstrained Requirement Plan] ), DIVIDE ( 1, [CURP-Consolidated URP] ) / 100,
//condition No. 6
ISBLANK ( [SFRP- Submitted Final Requirement Plan] )
&& ISBLANK ( [CURP-Consolidated URP] ), DIVIDE ( 1, [URP-Unconstrained Requirement Plan] ) / 100,
//condition No. 2
ISBLANK ( [URP-Unconstrained Requirement Plan] )
|| [URP-Unconstrained Requirement Plan] = 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], [CURP-Consolidated URP] ) / 100,
//condition No. 3
ISBLANK ( [CURP-Consolidated URP] ), DIVIDE (
[SFRP- Submitted Final Requirement Plan],
[URP-Unconstrained Requirement Plan]
) / 100,
//condition No. 7
[URP-Unconstrained Requirement Plan] = [CURP-Consolidated URP]
&& [CURP-Consolidated URP] = [SFRP- Submitted Final Requirement Plan], 0,
//condition No. 8
[CURP-Consolidated URP] = 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], 100 ),
//condition No. 9
[CURP-Consolidated URP] = 0
&& [URP-Unconstrained Requirement Plan] = 0, DIVIDE ( [SFRP- Submitted Final Requirement Plan], 100 ),
//condition No. 10
[CURP-Consolidated URP] = 0
&& [URP-Unconstrained Requirement Plan] = 0
&& [SFRP- Submitted Final Requirement Plan] = 0, 0
)
Saludos
Hola amitchandak,
Quiero crear una nueva columna como Difference% usando por debajo de 10 niveles de fila de condición, pude crear de 2 a 6 condiciones,
Condición: 1, 7, 8, 9 y 10 no soy capaz de hacer?
S.No | CURP | Urp | SFRP | Diferencia % | Dax para cada cálculo de nivel de fila |
1 | N/A | SI las tres columnas están en blanco | |||
2 | 100 | 90 | (90/100)% | SFRP/CURP. Cuando URP está en blanco | |
3 | 50 | 90 | (90/50)% | SFRP/URP. Cuando CURP está en blanco | |
4 | 90 | (90/1)% | SFRP/1. Cuando CURP y URP están en blanco | ||
5 | 100 | (1/100)% | 1/CURP. Cuando SFRP y URP están en blanco | ||
6 | 50 | (1/50)% | 1/URP. Cuando SFRP y CURP están en blanco | ||
7 | 100 | 100 | 100 | (100/100)% - 0% | Debe ser 0% cuando todos tienen el mismo valor |
8 | 0 | 100 | 50 | 50% | Cuando CURP es 0 considere el valor SFRP como Porcentaje |
9 | 0 | 0 | 50 | 50% | Cuando CURP y URP son 0, considere el valor SFRP como Porcentaje |
10 | 0 | 0 | 0 | 0% | Cuando CURP, URP y SFRP son 0, considere el valor como Porcentaje |
¿Puedes por favor ayudarme en esto?
saludos
Día