Skip to main content

Notifications

Announcements

No record found.

Customer experience | Sales, Customer Insights,...
Suggested answer

Which Entity / Field shows the Business Units that a record has been shared with?

Posted on by 202

Hi everyone

My employer has 26 Business Units within Dynamics, and records are shared between these Unit. My personal record is shared with around of these Business Units.

However, when I view my record (in SQL or Power BI) by looking at the Contact Entity, I can only find details of the Owning Business Unit. Where would I need to look for details of the other Business Units that my record is shared with?

I've looked at this article - https://www.linkedin.com/pulse/dynamics-365-view-shared-records-hussein-fawzy/ - but cannot find the POA table when using SQL or Power BI.

Many thanks
Jon

  • Suggested answer
    Bipin D365 Profile Picture
    Bipin D365 28,964 Super User 2024 Season 1 on at
    RE: Which Entity / Field shows the Business Units that a record has been shared with?

    Hi,

    Check if you are providing correct password?

    Also, try with different User account. Have you enabled MFA on your user account?

    Please mark my answer verified if this is helpful!

    Regards,

    Bipin Kumar

    Follow my Blog: xrmdynamicscrm.wordpress.com/

  • JonClay Profile Picture
    JonClay 202 on at
    RE: Which Entity / Field shows the Business Units that a record has been shared with?

    Hi there

    Many thanks for your reply.

    Unfortunately I'm getting the following error when I try to sigin to CDS:



    Do you know why this could be?

    Many thanks
    Jon

  • Suggested answer
    Bipin D365 Profile Picture
    Bipin D365 28,964 Super User 2024 Season 1 on at
    RE: Which Entity / Field shows the Business Units that a record has been shared with?

    Hi,

    To query POA table from Power Bi, I tried below approach and it is working -

    Open Power BI Desktop->Get Data->Power Platform->Common Data Service (Legacy)->Provide Service URL/CRM URL->Select POA as highlighted below from System entities

    CR33.PNG

    Please mark my answer verified if this is helpful!

    Regards,

    Bipin Kumar

    Follow my Blog: xrmdynamicscrm.wordpress.com/

    CR34.PNG

  • Suggested answer
    Bipin D365 Profile Picture
    Bipin D365 28,964 Super User 2024 Season 1 on at
    RE: Which Entity / Field shows the Business Units that a record has been shared with?

    Hello,

    I am able to query POA table using SQL4CDS plugin in XRMToolbox.

    www.xrmtoolbox.com/.../

    Select  * FROM principalobjectaccess where objectid="cfa89936-0154-ec11-8f8e-6045bd733548"

    objectid -> Your Contact Record ID

    CR32.PNG

    You will get UserId/TeamId in response, now to get the BU you will need to do join with systemuser/team table.

    /*For User*/

    Select * FROM principalobjectaccess p
    inner join systemuser s on p.principalid=s.systemuserid
    where p.objectid="cfa89936-0154-ec11-8f8e-6045bd733548" and p.principaltypecode="systemuser"
    /*For Team*/

    Select * FROM principalobjectaccess p
    inner join team t on p.principalid=t.teamid
    where p.objectid="cfa89936-0154-ec11-8f8e-6045bd733548" and p.principaltypecode="team"

    Please mark my answer verified if this is helpful!

    Regards,

    Bipin Kumar

    Follow my Blog: xrmdynamicscrm.wordpress.com/

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,280 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,214 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans