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
LFDSTHGroup
New Member

Agrupación

Hola a todos.

Tengo los siguientes datos:

LFDSTHGroup_0-1685102681802.png

 

 

Como podeis ver se trata de un mismo cliente, que se le ha visitado en 3 días diferentes, y en alguno de esos días se ha tenido más de una reunión

 

Lo que tengo es el dato del recuento de reuniones que he tenido con ese cliente (5), pero lo que busco además es el nº de visitas por cliente (3), independientemente de cuantas reuniones haya tenido.

Es decir, busco agrupar por fecha: Al cliente Contoso le he visitado en (3) fechas distintas, en este año (periodo escogido)

 

Lo he intentado con esta fórmula, pero no logro el resultado buscado

 

CALCULATE(COUNT(Citas[Cliente]),FILTER(Citas,DISTINCT(Citas[Fecha reunión])),USERELATIONSHIP('Periodo escogido'[Date],Citas[Fecha reunión]))

 

 

Gracias por la ayuda

2 REPLIES 2
LFDSTHGroup
New Member

Muchas gracias por la respuesta.

Aunque la solución que me propones solo funciona si los datos están filtrados por un solo cliente (1): reuniones (5) y visitas (3)

 

LFDSTHGroup_0-1685364168195.png

 

Pero cuando deseo ver las visitas de todos los clientes, entonces el dato no es correcto (debería ser un número entre el 187 y 297)

 

LFDSTHGroup_1-1685364378413.png

 

Núm. Visitas Realizadas (Actual) = CALCULATE(SUMX(VALUES(Citas[Fecha inicio]),DISTINCTCOUNT(Citas[_sth_cuenta_value])),USERELATIONSHIP('Periodo Actual'[Date],Citas[Fecha inicio]))
 
¿Donde puede estar el error?
 
Gracias por la ayuda
Syndicate_Admin
Administrator
Administrator

¡Prueba esto!

Visits to Client = sumx(VALUES(Appointment[Meeting Date]),DISTINCTCOUNT(Appointment[Client]))

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.

Community News

Fabric Community News unified experience

Read the latest Fabric Community announcements, including updates on Power BI, Synapse, Data Factory and Data Activator.

Dashboard in a day with date

Exclusive opportunity for Women!

Join us for a free, hands-on Microsoft workshop led by women trainers for women where you will learn how to build a Dashboard in a Day!

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