cancel
Showing results for 
Search instead for 
Did you mean: 

Fabric is Generally Available. Browse Fabric Presentations. Work towards your Fabric certification with the Cloud Skills Challenge.

Reply
Rabur116
Frequent Visitor

Recuento distinto de objetopor tipo y fecha

Hola

Tengo esta tabla donde necesito contar el número total general de objetos por fecha:

Nombre del objetoTipo de objetoFecha
abcvm1Ahv3/26/2020
abcvm2Vmw3/26/2020
bcdvm1Ahv3/25/2020
bcdvm1Ahv3/25/2020
bcdvm1Ahv3/24/2020
bcdvm1Vmw3/24/2020
cdwvm1Ahv3/24/2020

Un objeto debe contarse solo una vez al día si es del mismo tipo de objeto. La respuesta debe ser:

FechaAhvVmwTotal
3/26/2020112
3/25/2020101
3/24/2020213
Grand Total6

Estoy usando una visualización de "Tarjeta" para mostrar el Grand Total mientras filtro las fechas. Por favor, hágamelo saber la medida correcta que puedo utilizar para la "tarjeta".

¡Gracias de antemano!

2 ACCEPTED SOLUTIONS
Ashish_Mathur
Super User
Super User

Hola

Puede descargar mi archivo PBI desde aquí.

Espero que esto ayude.

Untitled.png


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

View solution in original post

v-easonf-msft
Community Support
Community Support

Hola , @Rabur116

Pruebe los pasos como se indica a continuación:

1.crear una tabla de cálculo:

Table 2 = DISTINCT('Table'[Object Type])

2.crear una medida como abajo

value1 =
SUMX (
    GROUPBY (
        FILTER ( 'Table', 'Table'[Object Type] IN DISTINCT ( 'Table 2'[Object Type] ) ),
        'Table'[Date],
        'Table'[Object Type]
    ),
    IF (
        ISBLANK ( CALCULATE ( DISTINCTCOUNT ( 'Table'[Object Name] ) ) ),
        0,
        CALCULATE ( DISTINCTCOUNT ( 'Table'[Object Name] ) )
    )
) + 0

Se mostrará como se muestra a continuación:

58.png

Aquí hay una demostración

pbix unido

Saludos
Equipo de Apoyo Comunitario _ Eason
Si este post ayuda,entonces por favor considere Aceptarlo como la solución para ayudar a los otros miembros a encontrarlo más rápidamente.

View solution in original post

6 REPLIES 6
v-easonf-msft
Community Support
Community Support

Hola , @Rabur116

Pruebe los pasos como se indica a continuación:

1.crear una tabla de cálculo:

Table 2 = DISTINCT('Table'[Object Type])

2.crear una medida como abajo

value1 =
SUMX (
    GROUPBY (
        FILTER ( 'Table', 'Table'[Object Type] IN DISTINCT ( 'Table 2'[Object Type] ) ),
        'Table'[Date],
        'Table'[Object Type]
    ),
    IF (
        ISBLANK ( CALCULATE ( DISTINCTCOUNT ( 'Table'[Object Name] ) ) ),
        0,
        CALCULATE ( DISTINCTCOUNT ( 'Table'[Object Name] ) )
    )
) + 0

Se mostrará como se muestra a continuación:

58.png

Aquí hay una demostración

pbix unido

Saludos
Equipo de Apoyo Comunitario _ Eason
Si este post ayuda,entonces por favor considere Aceptarlo como la solución para ayudar a los otros miembros a encontrarlo más rápidamente.

Hola, tanto la solución de primera persona como su solución funcionan. Muchas gracias por la ayuda!

De nada.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
amitchandak
Super User
Super User

@Rabur116

Trate como

Sumx(summarize(Table[Date],table,[ Object Type]"_dist",distinct(Table[Object Name])),[_dist])

Ashish_Mathur
Super User
Super User

Hola

Puede descargar mi archivo PBI desde aquí.

Espero que esto ayude.

Untitled.png


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

¡Tu solución funciona! Muchas gracias por la ayuda.

Helpful resources

Announcements
PBI November 2023 Update Carousel

Power BI Monthly Update - November 2023

Check out the November 2023 Power BI update to learn about new features.

Power BI Fabric Summit Carousel

The largest Power BI and Fabric virtual conference

130+ sessions, 130+ speakers, Product managers, MVPs, and experts. All about Power BI and Fabric. Attend online or watch the recordings.

Top Solution Authors