Forum Discussion

Ashishvca's avatar
Ashishvca
Frequent Visitor
4 years ago
Solved

Calculated measure not working after publishing

Hi

 

I am using calculated measure which are working fine on desktop but not working after I publish them. 

Here is the formula I am using 

Direct Selling = -(CALCULATE(sum(Consolidated[USD]),(Consolidated[Account]="Direct_Selling")))
 
This is the error I am getting

Fields that need to be fixedSomething's wrong with one or more fields: (Consolidated) Direct Selling, (Consolidated) Direct Marketing, (Consolidated) Local ID, (Consolidated) Strength

Please try again later or contact support. If you contact support, please provide these details.Hide details
 
Need help in fixing this

Thanks in advance.



  • You have more parentheses than you need. Two extra sets. Try this:

    Direct Selling =
    - CALCULATE(
        SUM( Consolidated[USD] ),
        Consolidated[Account] = "Direct_Selling"
    )
    

    If that fails, then I'd need to see the model image.

2 Replies

  • edhans's avatar
    edhans
    Icon for Community Champion rankCommunity Champion

    You have more parentheses than you need. Two extra sets. Try this:

    Direct Selling =
    - CALCULATE(
        SUM( Consolidated[USD] ),
        Consolidated[Account] = "Direct_Selling"
    )
    

    If that fails, then I'd need to see the model image.

  • v-kkf-msft's avatar
    v-kkf-msft
    Icon for Community Support rankCommunity Support

    Hi Ashishvca ,

     

    Have you changed field names or table name in Power BI Desktop file? To fix this, please delete your Service dataset and then re-publish your pbix file.

     

     

    If the problem is still not resolved, please provide detailed error information or the expected result you expect. Let me know immediately, looking forward to your reply.
    Best Regards,
    Winniz
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.