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

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Get child records with current records with their Notes in SSRS report

(0) ShareShare
ReportReport
Posted on by 297

Hello Everyone! Hope all of you are happy.

I open my record and run my SSRS report. So i want in report current record and child records of current records with their Notes are fetched. So can anyone tell me how to get such query using Advanced Find ? It will more helpful if you also tell me which controls should i use in report.

Pattern is following:

Current Record Data

Child Record 1 Data

Notes Pics

Child Record 2 Data

Notes Pics

Child Record 3 Data

Notes Pics

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Pawar Pravin  Profile Picture
    5,237 on at
    RE: Get child records with current records with their Notes in SSRS report

    Hi There,

    1. First of all create query like below snapshot.

    pastedimage1569832422469v1.png

    2. In SSDT tool create table and add grouping with a. child record and then b. current record.

  • Microsoft Dynamics 365 Consultancy Profile Picture
    297 on at
    RE: Get child records with current records with their Notes in SSRS report

    Brother this query fetched all child records of child entity but i want to fetch only child record of parent record not all records so cooperate me please.

    I am also trying following but error occurs due to highlighted text 

    <fetch version="1.0" output-format="xml-platform" mapping="logical" distinct="true">

     <entity name="ci_audit">

       <attribute name="ci_auditid" />

       <attribute name="ci_name" />

       <attribute name="createdon" />

       <attribute name="ci_questionnaire" />

       <attribute name="ci_officersignature" />

       <attribute name="ci_auditdate" />

       <attribute name="ci_asset" />

       <order attribute="ci_name" descending="false" />

       <link-entity name="ci_auditresponse" from="ci_audit" to="ci_auditid" link-type="inner" alias="aa">

       <attribute name="ci_auditresponseid" />

       <attribute name="ci_name" />

       <attribute name="createdon" />

       <attribute name="ci_questionnaire" />

       <attribute name="ci_question" />

       <attribute name="ci_compliance" />

       <attribute name="ci_audit" />

       <attribute name="ci_answer" />

       <order attribute="ci_name" descending="false" />

         <filter type="and">

           <condition attribute="ci_audit" operator="eq" uiname="Audit 1" uitype="ci_audit" value="ci_auditid" />

         </filter>

       </link-entity>

     </entity>

    </fetch>

    Error is Following: 

    "An exception System.FormatException was thrown while trying to convert input value 'ci_auditid' to attribute 'ci_auditresponse.ci_audit'. Expected type of attribute value: System.Guid.Exception raised: Guid should contain 32 digits with 4 dashes (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx)"

  • Suggested answer
    Pawar Pravin  Profile Picture
    5,237 on at
    RE: Get child records with current records with their Notes in SSRS report

    Is it form level report ?

    If yes then add  <entity name="ci_audit" enableprefiltering="1"> in your fetchxml

  • Microsoft Dynamics 365 Consultancy Profile Picture
    297 on at
    RE: Get child records with current records with their Notes in SSRS report

    Yes but i am still testing in visual studio.  I tried enableprefiltering="1" . but not working. i am embedding child fields in table. First i tried in list control now tried in table but not working.

    2061.table.PNG

  • Suggested answer
    Pawar Pravin  Profile Picture
    5,237 on at
    RE: Get child records with current records with their Notes in SSRS report

    Try this one as well:

    <entity name="ci_audit" enableprefiltering="true">

  • Microsoft Dynamics 365 Consultancy Profile Picture
    297 on at
    RE: Get child records with current records with their Notes in SSRS report

    I tried but not working. Following is my query:

    <fetch version="1.0" output-format="xml-platform" mapping="logical" distinct="true">

     <entity name="ci_audit" enableprefiltering="true">

       <attribute name="ci_auditid" />

       <attribute name="ci_name" />

       <attribute name="createdon" />

       <attribute name="ci_questionnaire" />

       <attribute name="ci_officersignature" />

       <attribute name="ci_auditdate" />

       <attribute name="ci_asset" />

       <order attribute="ci_name" descending="false" />

       <link-entity name="ci_auditresponse" from="ci_audit" to="ci_auditid" link-type="inner" alias="aa">

       <attribute name="ci_auditresponseid" />

       <attribute name="ci_name" />

       <attribute name="createdon" />

       <attribute name="ci_questionnaire" />

       <attribute name="ci_question" />

       <attribute name="ci_compliance" />

       <attribute name="ci_audit" />

       <attribute name="ci_answer" />

       <order attribute="ci_name" descending="false" />

       </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

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 CRM (Archived)

#1
Wayne Walton Profile Picture

Wayne Walton 2

#2
Good.Panos Profile Picture

Good.Panos 1

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans