web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics 365 | Integration, Dataverse...
Suggested Answer

# of opportunities per account

(0) ShareShare
ReportReport
Posted on by 5

Hello - 

I'm creating a  view, pulling from a number of Tables which will eventually be accessed in PowerBi.

One of the columns I'd like to add is a column listing the number of opportunities per account. What's the best way to set this up?

thanks,

Lise

I have the same question (0)
  • Suggested answer
    Community Member Profile Picture
    on at

    Hi Lise ,

    Best option would be to create the roll up field and store the count in the account entity. With this, you don't need to do any calculation on your end. 

    Define rollup columns with Power Apps - Power Apps | Microsoft Docs

    3480.pastedimage1629856812378v1.png5381.pastedimage1629857164077v3.png

    Then you can add the field to the form and view you need, save and publish all customizations.

    Test:

    2476.pastedimage1629857627424v4.png

    Note: Rollup field calculated periodically so you won't get the exact count unless the field is update so in this case, you can use the workflow tools step to force the calculation.

    Dynamics-365-Workflow-Tools/Force Calculate Rollup Field.md at master · demianrasko/Dynamics-365-Workflow-Tools · GitHub

    Regards,

    Leah Ju

    Please mark as verified if the answer is helpful. Welcome to join hot discussions in Dynamics 365 Forums.

  • Suggested answer
    Pradeep Rai Profile Picture
    5,489 Moderator on at

    Hi Lise,

    If you want show the no of records in CRM then Rollup field would be the best choice.

    But if you are going towards power bi then you can directly use the POWER BI capability such as calculated column.

    you can refer below link which will help you to display the related records count in power bi.

    community.powerbi.com/.../224176

    Thanks,

    Pradeep.

  • Suggested answer
    Community Member Profile Picture
    on at

    Hi Lise,

    Yes, you can also add calculated column into table directly in power BI.

    Count = CALCULATE(COUNTROWS('opportunities'),FILTER('opportunities',[_parentaccountid_value]=accounts[accountid]))
    8372.pastedimage1629873499493v1.png

    Regards,

    Leah Ju

    Please mark as verified if the answer is helpful. Welcome to join hot discussions in Dynamics 365 Forums.

  • Lise G Profile Picture
    5 on at

    Thank you all! I'm going to try Leah's suggestion. Will let you know if i run into issues.

  • Lise G Profile Picture
    5 on at

    Thank you so much!!

  • Lise G Profile Picture
    5 on at

    I am learning workflows. To access is it through the Process Center: Processes? Flow Templates? or Microsoft Flows?

  • Suggested answer
    Community Member Profile Picture
    on at

    Hi Lise,

    If you wan to  create workflows, you need go Settings > Processes:

    pastedimage1630285850852v1.png

    If you want to create flows, you can go Microsoft Flows or access Power Automate(https://us.flow.microsoft.com/en-us/) directly.

    Regards,

    Leah Ju

    Please mark as verified if the answer is helpful. Welcome to join hot discussions in Dynamics 365 Forums.

  • Community Member Profile Picture
    on at

    Hi Lise,

    Please click Yes under "Did this answer your question?" to close this thread if the answer is helpful.

     pastedimage1630285615269v1.png

    Thanks. 

    Regards,

    Leah Ju

    Please mark as verified if the answer is helpful. Welcome to join hot discussions in Dynamics 365 Forums.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Microsoft Dynamics 365 | Integration, Dataverse, and general topics

#1
Siv Sagar Profile Picture

Siv Sagar 93 Super User 2025 Season 2

#2
#ManoVerse Profile Picture

#ManoVerse 76

#3
Martin Dráb Profile Picture

Martin Dráb 64 Most Valuable Professional

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans