cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Helper III
Helper III

Error de cálculo de Mdxscript (Modelo)

Hola

Estoy recibiendo un error

suvechha_0-1597394307532.png


para las medidas:

SDUserId - CALCULATE(
VALUES(SDUser[USERID]),
USERELATIONSHIP(WorkOrderStates[OWNERID], SDUser[USERID])
)



Tengo una consulta sql como abajo :

SELECCIONE el top 10 "wo"." WORKORDERID" COMO "ID de solicitud",
"aau"." FIRST_NAME" COMO "Requester",
"ti"." FIRST_NAME" COMO "Técnico",
"wo"." CREATEDTIME" COMO "Tiempo creado"
DESDE "WorkOrder" "wo" IZQUIERDA UNIRSE "SDUser" "sdu"
EN "wo"." REQUESTERID"-"sdu"." USERID"
IZQUIERDA UNIRSE a "AaaUser" "aau" EN "sdu"." USERID""aau"." USER_ID"
IZQUIERDA UNIRSE a "WorkOrderStates" "wos" EN "wo"." WORKORDERID"-"wos"." WORKORDERID"
IZQUIERDA UNIRSE a "SDUser" "td" EN "wos"." OWNERID""td"." USERID"
IZQUIERDA UNIRSE a "AaaUser" "ti" EN "td"." USERID""ti"." USER_ID"

Para obtener el valor Technicial , tengo que crear userrelationship() pero no funciona.
Por favor, ay den asistencia.

Gracias

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Super User IX
Super User IX

Re: Error de cálculo de Mdxscript (modelo)

@suvechha, necesita tener alguna operación como , min , max , count , sum

SDUserId - CALCULATE(
Count(SDUser[USERID]),
USERELATIONSHIP(WorkOrderStates[OWNERID], SDUser[USERID])
)

para obtener el top 10, usar topn o rango

Para rango Consulte estos enlaces
https://radacad.com/how-to-use-rankx-in-dax-part-2-of-3-calculated-measures
https://radacad.com/how-to-use-rankx-in-dax-part-1-of-3-calculated-columns
https://radacad.com/how-to-use-rankx-in-dax-part-3-of-3-the-finale
https://community.powerbi.com/t5/Community-Blog/Dynamic-TopN-made-easy-with-What-If-Parameter/ba-p/3...



Did I answer your question? Mark my post as a solution! Appreciate your Kudos!!
Dashboard of My Blogs !! YouTube Channel !! Connect on Linkedin

Proud to be a Super User!

View solution in original post

2 REPLIES 2
Highlighted
Super User IX
Super User IX

Re: Error de cálculo de Mdxscript (modelo)

@suvechha, necesita tener alguna operación como , min , max , count , sum

SDUserId - CALCULATE(
Count(SDUser[USERID]),
USERELATIONSHIP(WorkOrderStates[OWNERID], SDUser[USERID])
)

para obtener el top 10, usar topn o rango

Para rango Consulte estos enlaces
https://radacad.com/how-to-use-rankx-in-dax-part-2-of-3-calculated-measures
https://radacad.com/how-to-use-rankx-in-dax-part-1-of-3-calculated-columns
https://radacad.com/how-to-use-rankx-in-dax-part-3-of-3-the-finale
https://community.powerbi.com/t5/Community-Blog/Dynamic-TopN-made-easy-with-What-If-Parameter/ba-p/3...



Did I answer your question? Mark my post as a solution! Appreciate your Kudos!!
Dashboard of My Blogs !! YouTube Channel !! Connect on Linkedin

Proud to be a Super User!

View solution in original post

Community Support
Community Support

Re: Error de cálculo de Mdxscript (modelo)

Hola , @suvechha

Intente utilizar FIRSTNONBLANK(SDUser[USERID], 1) en lugar de SDUser[USERID].

Saludos
Equipo de soporte de la comunidad _ Eason

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

Upcoming Events

Experience what’s next for Power BI

See the latest Power BI innovations, updates, and demos from the Microsoft Business Applications Launch Event.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Get Ready for Power BI Dev Camp

Get Ready for Power BI Dev Camp

Mark your calendars and join us for our next Power BI Dev Camp!.

Top Solution Authors