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

CRM 365: Fetch Xml and Layout Xml for Link Entity attribute - Does not display link entity attributes in the sub grid

(0) ShareShare
ReportReport
Posted on by 50

Hi, 
I'm using Dynamics 365 and build a custom fetch xml for a sub grid

The link entity attributes are not displayed in the sub grid

Maybe you have a clue fro me?

Thanks

fetchXml = "<fetch version='1.0' output-format='xml-platform' mapping='logical' distinct='false'>" +
                           "  <entity name='hr_assignment'>" +
                           "    <attribute name='hr_assignmentid' />" +
                           "    <attribute name='hr_name' />" +
                           "    <attribute name='hr_standard_id' />" +
                           "        <filter type='and'>" +
                           "          <condition attribute='hr_tribunalid' operator='eq' uitype='hr_tribunal' value='" + Xrm.Page.data.entity.getId() + "' />" +
                           "          <condition attribute='hr_assignment_status' operator='eq' value='315840002' />" +
                           "          <condition attribute='hr_standard_id' operator='not-null' />" +
                           "        </filter>" +
                           "    <link-entity name='hr_judges' from='hr_judgesid' to='hr_judgeid' alias='a' link-type='outer' >" +
                           "       <attribute name='hr_lastname' />" +
                           "       <attribute name='hr_firstname' />" +
                           "    </link-entity>" +
                           "    <link-entity name='hr_standard' from='hr_standardid' to='hr_standard_id' alias='b' link-type='outer'>" +
                           "       <attribute name='hr_judge_role_id' />" +
                           "       <attribute name='statuscode' />" +
                           "    </link-entity>" +
                           "  </entity>" +
                           "</fetch>";

var LayoutXml = "<grid name='resultset' object='8' jump='hr_name' select='1' preview='1' icon='1'>" +
                " <row name='result' id='hr_assignment'>" +
                     "<cell name='hr_assignmentid' width='50' />" +
                     "<cell name='hr_name' width='100' />" +
                     "<cell name='hr_standard_id' width='50' />" +
                     "<cell name='a.hr_lastname' width='50' />" +
                     "<cell name='a.hr_firstname' width='100' />" +
                     "<cell name='b.hr_judge_role_id' width='50' />" +
                     "<cell name='b.statuscode' width='100' />" +
                "</row>" +
             "</grid>";

objSubGrid.control.SetParameter("layoutXml", LayoutXml);
objSubGrid.control.SetParameter("fetchXml", fetchXml);
objSubGrid.control.Refresh();           

*This post is locked for comments

I have the same question (0)
  • ashlega Profile Picture
    34,477 on at

    Hi,

     I don't think this is supported at all, so it may or may not work in different versions, and, also, may or may not break moving forward.. This may help somehow:

    community.dynamics.com/.../201756

     But, in general, it just falls into the "unsupported customizations" area.

  • Suggested answer
    Michel Gueli Profile Picture
    982 on at

    Is see object='8'. This is the systemuser entity. Are you sure about this?

    You could also Save your view and then check the saved result in the filtereduserquery entity.

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
SA-08121319-0 Profile Picture

SA-08121319-0 4

#1
Calum MacFarlane Profile Picture

Calum MacFarlane 4

#3
Alex Fun Wei Jie Profile Picture

Alex Fun Wei Jie 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans