Forum Discussion

sixathur's avatar
sixathur
Frequent Visitor
1 year ago

Multiple DAX measure issues

Hi,

I am trying to create a Bonus calculator for my report,

Measure 1: Total Visits (I counted all the rows in the report to get the total visits)

 

 

 

Measure 2: PTO Hours ( I sum all the PTO hours)

Measure 3: FTE - I need to calculate the FTE per employee, 40 hours is full-time hours, from there I need to calculate the Target Visits

Measure 3: Target Visits - 58 is the default visit for a full time employee (1 FTE), this measure should calculate the visit targer based on their FTE

 

Measure 4: Bonus - if the Total visits is higher than the visit target, get the difference then multiply by 15.

Issue: The main issue I am having with all these formula is when I calculate the Estimated Bonus, its giving me the total visits multiply by 15, if I use the slicer (date) it gives me the correct data but without any filters its totalling all the visits. 

 

What am I doing wrong? I really need help.

7 Replies

  • some_bih's avatar
    some_bih
    Community Champion

    Hi sixathur it is hard to spot issue/s without your model. CALCULATE  is used to modify filter context so please provide some sample file with data input and expected output.

    It could be something like relationship, or need to adjust your measures with SELECTEDVALUE for targeted filter context.

      • some_bih's avatar
        some_bih
        Community Champion

        Hi sixathur I could not see on picture your tables named in measures above, like

         

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi sixathur 

     

    I'd recommend putting these measures all in the same table visual, and then using the slicer to pick dates to see which measure might not return the correct value in some specific cases. From the current information, if the Estimated Bonus gives you the total visits multiply by 15, it means VisitTarget might return 0 at the same time. 

     

    Best Regards,
    Jing

  • v-echaithra's avatar
    v-echaithra
    Community Support

    Hi sixathur ,

    We would like to follow up to see if the solution provided by the super user resolved your issue. Please let us know if you need any further assistance.
    If our super user response resolved your issue, please mark it as "Accept as solution" and click "Yes" if you found it helpful.

     

    Regards,
    Chaithra.

  • v-echaithra's avatar
    v-echaithra
    Community Support

    Hi sixathur ,

    May I ask if you have gotten this issue resolved?

     

    If it is solved, please mark the helpful reply or share your solution and accept it as solution, it will be helpful for other members of the community who have similar problems as yours to solve it faster.

     

    Regards,
    Chaithra.

  • v-echaithra's avatar
    v-echaithra
    Community Support

    Hi sixathur ,

    We would like to follow up to see if the solution provided by the super user resolved your issue. Please let us know if you need any further assistance.
    If our super user response resolved your issue, please mark it as "Accept as solution" and click "Yes" if you found it helpful.

     

    Regards,
    Chaithra.