Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Hola
Por favor, aconséjelo. Situación simple, pero me quedé atascado.
Tengo una mesa que se ve así:
Necesito agruparlo por nombre, tomar min(OnDate)
y (aquí está la pregunta) tomar el Departamento que era cuando la fecha - min(OnDate)
Si me gusta:
Hola @nsbars_rt ,
Puede intentar crear una nueva columna calculada mediante la instrucción if.
Column =
VAR min_date = CALCULATE(MIN('TABLE'[ondate]),ALLEXCEPT('TABLE','TABLE'[name]))
return IF('TABLE'[ondate]=min_date,1)
Puede filtrar en el gráfico de tablas o crear una nueva tabla calculada.
Table 2 = SELECTCOLUMNS(FILTER('TABLE','TABLE'[Column]=1),"name",'TABLE'[name],"ondate",'TABLE'[ondate],"department",'TABLE'[department])
Saludos
Liang
Si este post ayuda, por favor considere Aceptarlo como la solución para ayudar a los otros miembros a encontrarlo más rápidamente.
@nsbars_rt, Pruebe lastnonblankvalue
https://docs.microsoft.com/en-us/dax/lastnonblankvalue-function-dax
lastnonblankvalue(Table[date],min(table[Department]))
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.