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
Syndicate_Admin
Administrator
Administrator

Desea mostrar solo el vicepresidente actual de empleados

Hola

Tengo datos de jerarquía de empleados de la siguiente manera,

VicepresidenteDirectorDirectorEmpleadofecha
AdánSotaFernandezSteve20/11/2019
OtrosSamsonMikkySteve13/12/2019
EnGuillermoMikkySteve15/2/2020
StokesSotaMikkySteve27/03/2020
VentosasGuillermoFernandezSteve15/07/2020
CarlSamsonFernandezSteve20/12/2020
MarxGuillermoMikkySteve1/1/2021
ShellySamsonFernandezSteve12/4/2021
WiongSotaMikkySteve8/8/2021

La columna Fecha es el día en que una persona se ha hecho vicepresidenta de Steve.
Tengo un empleado llamado Steve para quien el vicepresidente cambia con el tiempo. Quiero mostrarle al último vicepresidente de Steve, es decir, Wiong.
Traté de calcular la fecha máxima para obtener el vicepresidente actual de Steve,

maniquí =
Dónde _latestdate = MAXX(TODOSSELECCIONADOS('tabla'),'tabla'[Fecha])
devolución
_latestdate

pero cuando arrastro la columna Vicepresidente y la columna Empleado a la imagen, obtengo todos los Vicepresidentes de Steve y las fechas.

Por favor, ayúdame a hacerlo.

Gracias

AshDil.

1 ACCEPTED SOLUTION
Syndicate_Admin
Administrator
Administrator

Hay @AshDil ,

Si desea mostrar el vicepresidente actual en función de la última fecha para cada empleado, puede intentar:

Measure= 
var _date=MAXX(FILTER(ALL('Table'),[Employee]=MAX('Table'[Employee])),[date])
return CALCULATE(MAX('Table'[Vice-President]),ALLEXCEPT('Table','Table'[Employee]),'Table'[date]=_date)

Eyelyn9_1-1634780448704.png

Saludos
Eyelyn Qin
Si esta publicación ayuda,entonces considere Aceptarla como la solución para ayudar a los otros miembros a encontrarla más rápidamente.

View solution in original post

4 REPLIES 4
Syndicate_Admin
Administrator
Administrator

Hay @AshDil ,

Si desea mostrar el vicepresidente actual en función de la última fecha para cada empleado, puede intentar:

Measure= 
var _date=MAXX(FILTER(ALL('Table'),[Employee]=MAX('Table'[Employee])),[date])
return CALCULATE(MAX('Table'[Vice-President]),ALLEXCEPT('Table','Table'[Employee]),'Table'[date]=_date)

Eyelyn9_1-1634780448704.png

Saludos
Eyelyn Qin
Si esta publicación ayuda,entonces considere Aceptarla como la solución para ayudar a los otros miembros a encontrarla más rápidamente.

Syndicate_Admin
Administrator
Administrator

Seguro @AshDil Hágame saber si está funcionando o si encuentra alguna otra dificultad.

Syndicate_Admin
Administrator
Administrator

Hay @AshDil

Puede usar la columna vicepresidente con Último y Fecha con lo último como se muestra a continuación

Samarth_18_1-1634555517263.png

image.png

Gracias

Samarth

Hay @Samarth_18 ,

Gracias por compartir. Trabajaré en ello.

Gracias

AshDil.

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