Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics CRM (Archived)

Connections count

Posted on by 25

Is it possible to count how many "Knows" connections a contact has using the Advance Find function?  I'd like to report how many contacts only have 1 connection.

*This post is locked for comments

  • Suggested answer
    Kokulan Profile Picture
    Kokulan 18,048 on at
    RE: Connections count

    Hi

    You could download the XrmToolBox from this link : [View:https://www.xrmtoolbox.com/:750:50]

    Use the FetchXMLBuilder to run the above query

    ScreenClip-_5B00_290_5D00_.png

  • AnnaCoombs Profile Picture
    AnnaCoombs 25 on at
    RE: Connections count

    Thanks for your response - I dont know how to start a new FETCH query?

  • Suggested answer
    Kokulan Profile Picture
    Kokulan 18,048 on at
    RE: Connections count

    You could use FETCH query to get the count, see the example below

    <fetch version="1.0" output-format="xml-platform" mapping="logical" distinct="true" aggregate="true" >
    <entity name="connection" >
    <attribute name="connectionid" aggregate="countcolumn" alias="countConnections" distinct="true" />
    <filter type="and" >
    <condition attribute="record1roleid" operator="eq" uiname="connetion role" uitype="connectionrole" value="{8899231D-1514-423C-A06B-BF269558200A}" />
    </filter>
    <link-entity name="contact" from="contactid" to="record1id" link-type="inner" alias="aa" >
    <filter type="and" >
    <condition attribute="contactid" operator="eq" uiname="contact name" uitype="contact" value="{25A17064-1AE7-E611-80F4-E0071B661F01}" />
    </filter>
    </link-entity>
    </entity>
    </fetch>

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,253 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,188 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans